Fixing typo
This commit is contained in:
parent
c615d8f16a
commit
f9d338c42a
@ -9,7 +9,7 @@ pub fn solve_part1(file_path: &str) -> i32 {
|
|||||||
.lines()
|
.lines()
|
||||||
.map(|line| {
|
.map(|line| {
|
||||||
let tmp = line.split(',').collect::<Vec<&str>>();
|
let tmp = line.split(',').collect::<Vec<&str>>();
|
||||||
let firs_pair = tmp
|
let first_pair = tmp
|
||||||
.first()
|
.first()
|
||||||
.expect("First character error")
|
.expect("First character error")
|
||||||
.split('-')
|
.split('-')
|
||||||
@ -29,7 +29,7 @@ pub fn solve_part1(file_path: &str) -> i32 {
|
|||||||
.expect("Parsing number in first pair failed")
|
.expect("Parsing number in first pair failed")
|
||||||
})
|
})
|
||||||
.collect::<Vec<u32>>();
|
.collect::<Vec<u32>>();
|
||||||
if mutual_inclusion(&firs_pair, &second_pair) {
|
if mutual_inclusion(&first_pair, &second_pair) {
|
||||||
1
|
1
|
||||||
} else {
|
} else {
|
||||||
0
|
0
|
||||||
|
Loading…
Reference in New Issue
Block a user