Solution for 12.1.
This commit is contained in:
parent
2d71871cf4
commit
fbd7c8fb00
4 changed files with 163 additions and 0 deletions
20
2018/internal/day12/debug.go
Normal file
20
2018/internal/day12/debug.go
Normal file
|
@ -0,0 +1,20 @@
|
|||
package day12
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
)
|
||||
|
||||
func DebugPrintPlants(plants map[int]bool) {
|
||||
low, high := getPlantBounds(plants)
|
||||
|
||||
for i := low; i < high+1; i++ {
|
||||
fmt.Print(plantString(plants[i]))
|
||||
}
|
||||
fmt.Println()
|
||||
}
|
||||
|
||||
func DebugPrintRules(rules []*Rule) {
|
||||
for _, rule := range rules {
|
||||
fmt.Println(rule)
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue