Skip to content

Commit

Permalink
refactor(16/2024): make code more rusty
Browse files Browse the repository at this point in the history
  • Loading branch information
manhunto committed Dec 23, 2024
1 parent c217286 commit f47cdde
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/solutions/year2024/day16.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ impl Day16 {
vectors
.into_iter()
.filter(|vec| {
let element = grid.get_for_point(&vec.position());
element == Some(&'.') || element == Some(&'E')
grid.get_for_point(&vec.position())
.is_some_and(|element| ['.', 'E'].contains(element))
})
.collect_vec()
})
Expand Down

0 comments on commit f47cdde

Please sign in to comment.