summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sol.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/sol.py b/sol.py
index cbccf67..76b968e 100644
--- a/sol.py
+++ b/sol.py
@@ -138,11 +138,11 @@ def visualize(maze, Q):
Qev = Q.eval(x,y)
maxdir = argmax(Qev)
- line3 += f("' " + ("^" if maxdir == NORTH else " ") + " ")
- line5 += f(" " + ("v" if maxdir == SOUTH else " ") + " ")
- line1 += f(" %04.2f " % Qev[NORTH])
- line2 += f("%s%04.2f %04.2f%s" % ("<" if maxdir == WEST else " ",Qev[WEST], Qev[EAST], ">" if maxdir == EAST else " "))
- line4 += f(" %04.2f " % Qev[SOUTH])
+ line3 += f("' " + ("^" if maxdir == NORTH else " ") + " ")
+ line5 += f(" " + ("v" if maxdir == SOUTH else " ") + " ")
+ line1 += f(" %06.2f " % Qev[NORTH])
+ line2 += f("%s%06.2f %06.2f%s" % ("<" if maxdir == WEST else " ",Qev[WEST], Qev[EAST], ">" if maxdir == EAST else " "))
+ line4 += f(" %06.2f " % Qev[SOUTH])
print(line3)
print(line1)
print(line2)