Skip to content

Commit

Permalink
template: Include ability to read from file system
Browse files Browse the repository at this point in the history
  • Loading branch information
icyJoseph committed Dec 1, 2021
1 parent e101c4b commit 54a4b3f
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions template/src/main.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,20 @@
use aoc;

fn parse_num<T: std::str::FromStr>(str: &str) -> T {
match str.trim().parse::<T>() {
Ok(n) => n,
_ => panic!("Error parsing"),
}
}

fn solve(raw: String) -> () {
println!("{}", raw);
}

fn main() {
let input = aoc::get_input({{year}}, {{day}});

// let example_input = std::fs::read_to_string("").expect("Error reading input");

solve(input);
}

0 comments on commit 54a4b3f

Please sign in to comment.