started to think about solving the maze
This commit is contained in:
parent
cd7c65fc33
commit
66a370b634
@ -1,3 +1,4 @@
|
|||||||
from maze import make_maze
|
from maze import make_maze
|
||||||
|
|
||||||
print make_maze()
|
m = make_maze()
|
||||||
|
print m
|
||||||
|
@ -3,3 +3,4 @@ import sys
|
|||||||
from maze import parse_maze
|
from maze import parse_maze
|
||||||
|
|
||||||
m = parse_maze(sys.stdin.read())
|
m = parse_maze(sys.stdin.read())
|
||||||
|
print m.solve()
|
||||||
|
@ -7,6 +7,12 @@ class CS235Maze(object):
|
|||||||
self.data = data
|
self.data = data
|
||||||
self.size = size
|
self.size = size
|
||||||
|
|
||||||
|
def _solve(self, x, y, z):
|
||||||
|
return False, set()
|
||||||
|
|
||||||
|
def solve(self):
|
||||||
|
return self._solve(0, 0, 0)
|
||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
r = derp_transpose(self.data)
|
r = derp_transpose(self.data)
|
||||||
rs = ''
|
rs = ''
|
||||||
@ -35,7 +41,7 @@ def parse_maze(maze):
|
|||||||
for j in k.split('\n')]
|
for j in k.split('\n')]
|
||||||
for k in maze.split('\n\n') if k]
|
for k in maze.split('\n\n') if k]
|
||||||
cleaned = derp_transpose(soilded)
|
cleaned = derp_transpose(soilded)
|
||||||
return cleaned
|
return CS235Maze(cleaned)
|
||||||
|
|
||||||
|
|
||||||
def derp_transpose(s, size=8):
|
def derp_transpose(s, size=8):
|
||||||
|
Loading…
Reference in New Issue
Block a user