init day03
This commit is contained in:
parent
e32a8489e3
commit
1f37a7a7f3
2 changed files with 45 additions and 0 deletions
35
day03/day03.go
Normal file
35
day03/day03.go
Normal file
|
@ -0,0 +1,35 @@
|
|||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"io"
|
||||
"os"
|
||||
"strings"
|
||||
)
|
||||
|
||||
func readInput() string {
|
||||
stdin, err := io.ReadAll(os.Stdin)
|
||||
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
str := string(stdin)
|
||||
return str
|
||||
}
|
||||
|
||||
func part1(lines []string) {
|
||||
fmt.Println("Part 1 not implemented")
|
||||
}
|
||||
|
||||
func part2(lines []string) {
|
||||
fmt.Println("Part 2 not implemented")
|
||||
}
|
||||
|
||||
func main() {
|
||||
input := readInput()
|
||||
lines := strings.Split(input, "\n")
|
||||
fmt.Println("---PART 1---")
|
||||
part1(lines)
|
||||
fmt.Println("---PART 2---")
|
||||
part2(lines)
|
||||
}
|
10
day03/example.txt
Normal file
10
day03/example.txt
Normal file
|
@ -0,0 +1,10 @@
|
|||
467..114..
|
||||
...*......
|
||||
..35..633.
|
||||
......#...
|
||||
617*......
|
||||
.....+.58.
|
||||
..592.....
|
||||
......755.
|
||||
...$.*....
|
||||
.664.598..
|
Loading…
Add table
Reference in a new issue