Skip to content

Commit

Permalink
chore: take clippy suggestion
Browse files Browse the repository at this point in the history
Signed-off-by: Henry Schreiner <[email protected]>
  • Loading branch information
henryiii committed Sep 18, 2024
1 parent e9f82a4 commit 367a6ea
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/bin/12.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,7 @@ fn cmp_line(conditions: String, ops: Vec<usize>) -> usize {
.chars()
.skip(space)
.take(ops[0])
.enumerate()
.all(|(_, c)| c != '.')
.all(|c| c != '.')
&& conditions.chars().nth(space + ops[0]).unwrap_or('.') != '#';
if conditions.chars().skip(space + ops[0]).count() < 2 {
count += usize::from(valid);
Expand Down

0 comments on commit 367a6ea

Please sign in to comment.