Day 2 scaffold
This commit is contained in:
parent
2e4a4a8df5
commit
8a05a81128
1 changed files with 32 additions and 0 deletions
32
2022/rust/src/day2.rs
Normal file
32
2022/rust/src/day2.rs
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
mod common;
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
let input = common::day_input(2);
|
||||||
|
println!("Part 1: {}", part1(&input));
|
||||||
|
println!("Part 2: {}", part2(&input));
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part1(input: &str) -> i32 {
|
||||||
|
0
|
||||||
|
}
|
||||||
|
|
||||||
|
fn part2(input: &str) -> i32 {
|
||||||
|
0
|
||||||
|
}
|
||||||
|
|
||||||
|
#[cfg(test)]
|
||||||
|
mod tests {
|
||||||
|
use super::*;
|
||||||
|
|
||||||
|
const TEST_INPUT: &str = "0";
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn test_part1() {
|
||||||
|
assert_eq!(part1(TEST_INPUT), 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
#[test]
|
||||||
|
fn test_part2() {
|
||||||
|
assert_eq!(part2(TEST_INPUT), 0)
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue