Correct formatting.

This commit is contained in:
2019-02-18 15:13:48 +01:00
parent 171d9fa2e9
commit c16ef40d73
28 changed files with 316 additions and 195 deletions

View File

@@ -17,7 +17,8 @@ impl common::Solution for Day01 {
fn part1(&mut self, input: &mut io::Read) -> String {
let reader = io::BufReader::new(input);
let sum: i32 = reader.lines()
let sum: i32 = reader
.lines()
.map(|x| x.unwrap().parse::<i32>().unwrap())
.sum();
@@ -30,7 +31,8 @@ impl common::Solution for Day01 {
freqs.insert(0);
let mut sum = 0;
let nums: Vec<i32> = reader.lines()
let nums: Vec<i32> = reader
.lines()
.map(|x| x.unwrap().parse().unwrap())
.collect();
loop {