time tracking
This commit is contained in:
parent
4f191d8689
commit
cda502d79c
@ -1,3 +1,5 @@
|
|||||||
|
use std::time::Instant;
|
||||||
|
|
||||||
struct SField {
|
struct SField {
|
||||||
field: Vec<usize>,
|
field: Vec<usize>,
|
||||||
fixed: Vec<usize>,
|
fixed: Vec<usize>,
|
||||||
@ -401,9 +403,11 @@ impl SField {
|
|||||||
|
|
||||||
#[inline(always)]
|
#[inline(always)]
|
||||||
fn solve(&mut self) {
|
fn solve(&mut self) {
|
||||||
|
let now = Instant::now();
|
||||||
if !self.solve_backtracking() {
|
if !self.solve_backtracking() {
|
||||||
println!("there is no solution.");
|
println!("there is no solution.");
|
||||||
}
|
}
|
||||||
|
println!("took {:.3}s", now.elapsed().as_secs_f64());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user