We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8991a07 commit d6c71d4Copy full SHA for d6c71d4
src/year2016/day18.rs
@@ -41,7 +41,7 @@ fn count(input: &str, rows: u32) -> u32 {
41
// Count the traps in each row.
42
total += row.count_ones();
43
// Only consider the left and right values for the next row.
44
- row = (row << 1) ^ (row >> 1) & mask;
+ row = ((row << 1) ^ (row >> 1)) & mask;
45
}
46
47
// We want the number of safe tiles so convert from the number of traps.
0 commit comments