Run cargo fmt
This commit is contained in:
parent
fe14fed68c
commit
6bfae0fe45
|
@ -3,7 +3,6 @@ use std::fs::File;
|
|||
use std::io::{self, BufRead};
|
||||
use std::path::Path;
|
||||
|
||||
|
||||
pub fn read_lines<P>(filename: P) -> io::Result<io::Lines<io::BufReader<File>>>
|
||||
where
|
||||
P: AsRef<Path>,
|
||||
|
|
|
@ -16,7 +16,6 @@ pub fn part_two() -> String {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
fn parse_line(s: &str) -> u32 {
|
||||
const RADIX: u32 = 10;
|
||||
|
||||
|
|
|
@ -22,8 +22,6 @@ pub fn part_two() -> String {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
fn process_line(s: &str) -> u32 {
|
||||
let v: Vec<&str> = s.split(':').collect();
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
pub mod part_one;
|
||||
|
||||
|
||||
use crate::utils::solution::Solution;
|
||||
|
||||
pub struct Day3Solution;
|
||||
|
|
|
@ -19,7 +19,6 @@ pub fn part_one() -> String {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
fn create_matrix(lines: io::Lines<io::BufReader<File>>) -> Vec<Vec<Engine>> {
|
||||
let mut matrix: Vec<Vec<Engine>> = Vec::new();
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
pub mod part_one;
|
||||
|
||||
|
||||
use crate::utils::solution::Solution;
|
||||
|
||||
pub struct Day4Solution;
|
||||
|
|
|
@ -17,7 +17,6 @@ pub fn part_one() -> String {
|
|||
}
|
||||
|
||||
fn process_line(s: &str) -> u32 {
|
||||
|
||||
let mut winning_numbers = HashSet::new();
|
||||
let mut res = 0;
|
||||
|
||||
|
@ -45,5 +44,3 @@ fn process_line(s: &str) -> u32 {
|
|||
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
pub mod part_one;
|
||||
pub mod part_two;
|
||||
|
||||
|
||||
use crate::utils::solution::Solution;
|
||||
|
||||
pub struct Day6Solution;
|
||||
|
|
|
@ -40,5 +40,3 @@ fn process_race_result(time: u32, distance: u32) -> u32 {
|
|||
|
||||
return win_count;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -37,5 +37,3 @@ fn process_race_result(time: u64, distance: u64) -> u64 {
|
|||
|
||||
return win_count;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue