diff --git a/src/day12/day12.go b/src/day12/day12.go index aa44097..979d8a1 100644 --- a/src/day12/day12.go +++ b/src/day12/day12.go @@ -8,16 +8,6 @@ import ( "unicode" ) -type pathTracking struct { - route []string - visitedSmallCaveTwice bool -} - -type stepTracking struct { - destiny string - visitedSmallCaveTwice bool -} - func main() { args := os.Args[1:] input, err := helper.GetInput(args[0]) @@ -31,7 +21,9 @@ func main() { if splitLine[0] != "start" && splitLine[1] != "end" { routeMap[splitLine[1]] = append(routeMap[splitLine[1]], splitLine[0]) } - routeMap[splitLine[0]] = append(routeMap[splitLine[0]], splitLine[1]) + if splitLine[1] != "start" && splitLine[0] != "end" { + routeMap[splitLine[0]] = append(routeMap[splitLine[0]], splitLine[1]) + } } for key, val := range routeMap { fmt.Printf("%s : %s \n", key, val)