add runtime measurement

This commit is contained in:
2024-12-10 11:45:53 +01:00
parent 64cb7fb370
commit dd6e9dbe90
54 changed files with 417 additions and 47 deletions

View File

@@ -1,10 +1,17 @@
use std::fs;
use std::{fs, time::Instant};
use utils::time::get_elapsed_string;
use y{{YEAR}}::days::d{{DAY}};
fn main() {
let now = Instant::now();
println!("Part 1:");
part1();
println!("Ran in {}", get_elapsed_string(now.elapsed()));
let now = Instant::now();
println!("Part 2:");
part2();
println!("Ran in {}", get_elapsed_string(now.elapsed()));
}
fn part1() {