Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dashed committed Dec 6, 2023
1 parent dbb4161 commit 4bee9d3
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions 2018/day-14-2018/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,8 @@ fn part_1(part_1_input: usize) -> String {
.iter()
.skip(part_1_input)
.take(10)
.map(|x| x.to_string())
.collect::<Vec<String>>()
.join("");
.map(std::string::ToString::to_string)
.collect::<String>();

return result;
}
Expand Down Expand Up @@ -145,12 +144,12 @@ fn part_2(part_1_input: String) -> usize {
}

fn main() {
let input = 540391;
let input = 540_391;
let result = part_1(input);
println!("Part 1: {}", result);
println!("Part 1: {result}");

let result = part_2(input.to_string());
println!("Part 2: {}", result);
println!("Part 2: {result}");
}

#[cfg(test)]
Expand Down

0 comments on commit 4bee9d3

Please sign in to comment.