-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathMarkSolverTest.py
68 lines (54 loc) · 2.08 KB
/
MarkSolverTest.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
from MarkSolver import *
from nodeclass import *
if True:
map1= [[0,0,0,0],[0,0,0,0],[0,0,0,3],[0,0,0,0]]
print("Should be true:")
if(marksolver(maptrans(map1),4,4)): print("true")
else: print("false")
map2= [[0,1,0,0],[1,1,1,1],[0,0,0,3],[0,0,1,0]]
print("Should be false:")
if(marksolver(maptrans(map2),4,4)): print("true")
else: print("false")
map3= [[0,0,2,0],[0,0,0,3],[1,0,0,0],[0,0,0,0]]
print("Should be true:")
if(marksolver(maptrans(map3),4,4)): print("true")
else: print("false")
map4=[[0,0,1,0],[0,0,0,3],[1,0,0,0],[0,0,0,0]]
print("Should be false:")
if(marksolver(maptrans(map4),4,4)): print("true")
else: print("false")
map5=[[0,0,0,1],[0,0,2,3],[1,1,0,0],[0,0,0,0]]
print("Should be true:")
if(marksolver(maptrans(map5),4,4)): print("true")
else: print("false")
map6 =[[0,0,0,0],[0,0,0,0],[1,1,0,1],[3,0,2,0]]
print("Should be true:")
if(marksolver(maptrans(map6),4,4)): print("true")
else: print("false")
map7=[[0,0,0,0],[0,0,0,2],[1,0,0,3],[0,0,0,0]]
print("Should be true:")
if(marksolver(maptrans(map7),4,4)): print("true")
else: print("false")
map8=[[0,0,2,3],[0,0,0,0],[0,0,0,1],[1,1,0,0]]
print("Should be true:")
if(marksolver(maptrans(map8),4,4)): print("true")
else: print("false")
map9 =[[0,0,0,1],[0,0,1,0],[0,1,0,0],[3,0,2,0]]
print("Should be true:")
if(marksolver(maptrans(map9),4,4)): print("true")
else: print("false")
map10 =[[0,0,1,0],[0,0,0,1],[2,0,3,0],[1,1,0,0]]
print("Should be true:")
if(marksolver(maptrans(map10),4,4)): print("true")
else: print("false")
map11=[[0,0,0,1],[0,0,1,0],[0,1,0,0],[2,0,3,0]]
print("Should be true:")
if(marksolver(maptrans(map11),4,4)): print("true")
else: print("false")
map12=[[0,0,1,0],[0,0,0,3],[0,2,0,0],[0,0,0,1]]
print("Should be true:")
if(marksolver(maptrans(map12),4,4)): print("true")
else: print("false")
map13=[[0,0,0,0],[0,0,1,0],[1,2,3,0],[1,0,0,0]]
if(marksolver(maptrans(map13),4,4)): print("true")
else: print("false")