1
0

Fixing typo

This commit is contained in:
Pcornat 2022-12-08 22:09:26 +01:00
parent c615d8f16a
commit f9d338c42a
Signed by: Pcornat
GPG Key ID: 2F3932FF46D9ECA0

View File

@ -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