Improved solving; should now solve all easy puzzles.
[pseudoku.git] / pseudoku / __init__.py
index 853904b..c7a803b 100644 (file)
@@ -1,4 +1,5 @@
 from grid import Grid
 from grid import Grid
+from grid.constraints import Diagonal
 import render.text
 
 def main():
 import render.text
 
 def main():
@@ -14,6 +15,9 @@ def main():
         1...6...9
     """)
 
         1...6...9
     """)
 
+    grid.add_constraint(Diagonal(grid, direction='down', offset=0))
+    grid.add_constraint(Diagonal(grid, direction='up', offset=0))
+
     r = render.text.AsciiArtGridRenderer()
     print r.render_grid(grid)
 
     r = render.text.AsciiArtGridRenderer()
     print r.render_grid(grid)