From e41e6c8bc72e3300a0fa137f198454341bc315b1 Mon Sep 17 00:00:00 2001 From: mathiasmagnusson Date: Fri, 9 Dec 2022 18:00:02 +0100 Subject: Add aoc --- aoc22/lib/src/lib.rs | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 aoc22/lib/src/lib.rs (limited to 'aoc22/lib/src/lib.rs') diff --git a/aoc22/lib/src/lib.rs b/aoc22/lib/src/lib.rs new file mode 100644 index 0000000..ffe4e46 --- /dev/null +++ b/aoc22/lib/src/lib.rs @@ -0,0 +1,9 @@ +use std::fs; + +pub mod prelude { + pub use std::error::Error; +} + +pub fn read_input(day: usize) -> String { + fs::read_to_string(format!("day{}/input", day)).expect("Could not read input") +} -- cgit v1.2.3