day07
This commit is contained in:
@@ -13,6 +13,7 @@ import (
|
||||
"adventofcode2023/day04"
|
||||
"adventofcode2023/day05"
|
||||
"adventofcode2023/day06"
|
||||
"adventofcode2023/day07"
|
||||
)
|
||||
// Usage: go run main.go <NN>
|
||||
// assumes input is in day<NN>/input.txt
|
||||
@@ -39,6 +40,9 @@ func main() {
|
||||
case 6:
|
||||
fmt.Printf("part 1: %d\n", day06.Part1(utils.Readfile(d)))
|
||||
fmt.Printf("part 2: %d\n", day06.Part2(utils.Readfile(d)))
|
||||
case 7:
|
||||
fmt.Printf("part 1: %d\n", day07.Part1(utils.Readfile(d)))
|
||||
fmt.Printf("part 2: %d\n", day07.Part2(utils.Readfile(d)))
|
||||
default:
|
||||
panic(fmt.Errorf("no such day: %d", d))
|
||||
}
|
||||
@@ -46,7 +50,7 @@ func main() {
|
||||
|
||||
// Reads day from os.Args.
|
||||
func day() int {
|
||||
latest := 5
|
||||
latest := 6
|
||||
if len(os.Args) == 1 {
|
||||
return latest
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user