Skip to content

Commit

Permalink
fix square index 🤦
Browse files Browse the repository at this point in the history
  • Loading branch information
Esgrove committed Feb 23, 2024
1 parent a4dd69e commit 81d3bad
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rust/src/board.rs
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ impl Board {
#[allow(dead_code)]
/// Map square to index on board.
fn square_index(&self, square: &Square) -> usize {
square.x as usize * self.size + square.x as usize
square.y as usize * self.size + square.x as usize
}

/// Count and return the number of black and white disks.
Expand Down

0 comments on commit 81d3bad

Please sign in to comment.