Allow day 2 to run on any input
I had this in as a sanity check.
This commit is contained in:
@ -28,9 +28,6 @@ func (d *Day02) Part1() string {
|
|||||||
d.setParams(12, 2)
|
d.setParams(12, 2)
|
||||||
d.program.Run()
|
d.program.Run()
|
||||||
|
|
||||||
if d.program.GetMemory(0) != 4138658 {
|
|
||||||
panic("")
|
|
||||||
}
|
|
||||||
return fmt.Sprintf("Position 0 = %s%d%s", utilities.TextBold, d.program.GetMemory(0), utilities.TextReset)
|
return fmt.Sprintf("Position 0 = %s%d%s", utilities.TextBold, d.program.GetMemory(0), utilities.TextReset)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -59,9 +56,6 @@ func (d *Day02) Part2() string {
|
|||||||
if !found {
|
if !found {
|
||||||
panic("!found")
|
panic("!found")
|
||||||
}
|
}
|
||||||
if noun != 72 || verb != 64 {
|
|
||||||
panic("")
|
|
||||||
}
|
|
||||||
|
|
||||||
return fmt.Sprintf("%d created by noun=%d, verb=%d. 100 * noun + verb = %s%d%s",
|
return fmt.Sprintf("%d created by noun=%d, verb=%d. 100 * noun + verb = %s%d%s",
|
||||||
sentinel,
|
sentinel,
|
||||||
|
Reference in New Issue
Block a user