Files
aoc22/src/bin/d9p1.rs
2022-12-15 11:35:33 +01:00

15 lines
352 B
Rust

use aoc22::{day9, util};
pub fn main() {
let motions = day9::parse_motions(&util::parse_input());
let mut state = day9::State::new(1);
for motion in &motions {
day9::execute_motion(&mut state, &motion);
}
println!("State after all motions:");
state.print();
println!("Visited fields: {}", state.visited.len());
}