Permalink
Browse files

* src/main/clojure/clojure/core/logic/bench.clj: include hard one fro…

…m wikipedia
  • Loading branch information...
David Nolen David Nolen
David Nolen authored and David Nolen committed Aug 1, 2012
1 parent ed614bf commit 1fa49b2d82794f6780237c77b50542ea00a18436
Showing with 21 additions and 0 deletions.
  1. +21 −0 src/main/clojure/clojure/core/logic/bench.clj
@@ -593,4 +593,25 @@
(time
(dotimes [_ 10]
(sudokufd hard1))))
+
+ ;; from Wikipedia
+ (def hard2
+ [1 2 0 4 0 0 3 0 0
+ 3 0 0 0 1 0 0 5 0
+ 0 0 6 0 0 0 1 0 0
+
+ 7 0 0 0 9 0 0 0 0
+ 0 4 0 6 0 3 0 0 0
+ 0 0 3 0 0 2 0 0 0
+
+ 5 0 0 0 8 0 7 0 0
+ 0 0 7 0 0 0 0 0 5
+ 0 0 0 0 0 0 0 9 8])
+
+ (time (sudokufd hard2))
+
+ ;; ~570ms
+ (dotimes [_ 5]
+ (time
+ (sudokufd hard2)))
)

0 comments on commit 1fa49b2

Please sign in to comment.