Skip to content

Commit aa908ab

Browse files
committed
minor 2024_02
1 parent 58976a8 commit aa908ab

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/bin/2024_02/main.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ fn good_difference(seq: &[u32]) -> bool {
66
.windows(2)
77
.map(|w| i64::from(w[1]) - i64::from(w[0]))
88
.collect();
9-
diff_seq.iter().all(|x| *x >= 1 && *x <= 3)
10-
|| diff_seq.iter().all(|x| *x >= -3 && *x <= -1)
9+
diff_seq.iter().all(|x| *x >= 1 && *x <= 3) || diff_seq.iter().all(|x| *x >= -3 && *x <= -1)
1110
}
1211

1312
fn good_sequence<const PART: usize>(seq: &[u32]) -> bool {

0 commit comments

Comments
 (0)