Minor edit

master
Mark 2024-03-06 10:36:04 -08:00
parent b39c618a2a
commit 00270569db
Signed by: Mark
GPG Key ID: C6D63995FE72FD80
1 changed files with 1 additions and 2 deletions

View File

@ -57,8 +57,7 @@ pub fn free_slots_by_influence(board: &Board) -> Option<Vec<(usize, f32)>> {
pub fn best_board_noop(board: &Board, minimize: bool) -> Option<Board> { pub fn best_board_noop(board: &Board, minimize: bool) -> Option<Board> {
let n_free = board.get_board().iter().filter(|x| x.is_none()).count(); let n_free = board.get_board().iter().filter(|x| x.is_none()).count();
// TODO: fix zero division let available_numbers = (0..=9)
let available_numbers = (1..=9)
.map(|x| match x { .map(|x| match x {
0 => Symb::Zero, 0 => Symb::Zero,
x => Symb::Number(NonZeroU8::new(x).unwrap()), x => Symb::Number(NonZeroU8::new(x).unwrap()),