Day 15: Part 2

Signed-off-by: James Griffin <james@unsupervised.ca>
This commit is contained in:
2020-12-15 20:13:06 -04:00
parent 4733cfa321
commit ab1a158f25
3 changed files with 26 additions and 0 deletions

View File

@@ -81,3 +81,13 @@ func PartOne() string {
return fmt.Sprintf("The 2020th number is %d", g.valueAt(2020))
}
// PartTwo What is the 30000000th number given my input
func PartTwo() string {
g := game{}
if err := g.load("fifteen/input.txt"); err != nil {
return err.Error()
}
return fmt.Sprintf("The 30000000th number is %d", g.valueAt(30000000))
}