Day 24
This commit is contained in:
15
day24/ex2/main.go
Normal file
15
day24/ex2/main.go
Normal file
@@ -0,0 +1,15 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"aoc2022/day24/common"
|
||||
"bufio"
|
||||
"fmt"
|
||||
"os"
|
||||
)
|
||||
|
||||
func main() {
|
||||
tileMap := common.Parse(*bufio.NewScanner(os.Stdin))
|
||||
current := tileMap.GetDistanceToEnd(0)
|
||||
current = tileMap.GetDistanceToStart(current)
|
||||
fmt.Println(tileMap.GetDistanceToEnd(current))
|
||||
}
|
||||
Reference in New Issue
Block a user