diff options
Diffstat (limited to 'graph-checker/src/main.rs')
| -rw-r--r-- | graph-checker/src/main.rs | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/graph-checker/src/main.rs b/graph-checker/src/main.rs index 628ce92..646cca0 100644 --- a/graph-checker/src/main.rs +++ b/graph-checker/src/main.rs @@ -1,4 +1,4 @@ -use std::io::{self, BufRead}; +// use std::io::{self, BufRead}; use std::time::Instant; mod graph; @@ -7,6 +7,9 @@ use crate::graph::Graph; mod theorems; use crate::theorems::{basic, forbidden, toughness}; +mod geng; +use crate::geng::GengIterator; + struct Counters { graphs: i32, tough_1: i32, @@ -56,16 +59,14 @@ impl Counters { } fn main() { - let stdin = io::stdin(); + let gi = GengIterator::new(4); let mut time = 0; let mut counters = Counters::new(); - for line in stdin.lock().lines() { - let line = line.unwrap(); - - let g = Graph::from_g6(&line); + for g in &gi { counters.graphs += 1; + let line = g.to_g6(); let start = Instant::now(); let closure = g.get_closure(); |