Add cost function.

This commit is contained in:
hal8174 2024-01-14 01:25:45 +01:00
parent 02e65f6fe3
commit 2bdfd8cc6c
3 changed files with 26 additions and 6 deletions

View file

@ -47,7 +47,7 @@ fn main() {
match args.mode {
Mode::Solutions => {
while b.next_finish_state() {
println!("{}\n{}\n{}", b.count(), b.solution_count(), b);
println!("{}\n{}\n{}\n{}", b.count(), b.solution_count(), b.cost(), b);
}
println!("Solutions: {}\nStates: {}", b.solution_count(), b.count());