Added all the test cases from PA1 for good.py for validation purposes.

master
Sanjar Ahmadov 4 years ago
parent 9e29fdf770
commit 64e82a191e

@ -1,2 +1,83 @@
x:int = 1 # Below this point we have all the same test cases from PA1 for validation purposes.
x * 1 class Foo(object):
x:int = 0
def __init__(self:"Foo", x:int):
self.x = x
def bar(y:int):
print("Hello World!",self.x+y)
y = 10
def get_stones(name:str)->str:
def map_name(nm:str)->str:
return stones[color.index(nm)]
color=["Red","Blue"]
stones=["Mind","Soul"]
return map_name(name)
def funa():
def funb():
print("Hello")
funb()
def fund():
def fune():
print("Hello")
c = 4 + 5
def funf():
def fung():
print("Hello")
c = 6
c = 4 + 5
if True:
if True:
if True:
print("Hello")
print("World")
if True:
if True:
if True:
print("Hello")
print("World")
if True:
if True:
if True:
print("Hello")
print("World")
if True:
if True:
if True:
print("Hello")
else:
print("World")
if True:
if True:
if True:
print("Hello")
else:
print("World")
f = Foo(1)
print(f.x)
f.bar(4)
a=[[[1],[2]],[[3],[4]]]
print(a[0][0][1]*a[1][1][0])
multiline_string="Hi World,\
Here I am"
expr_precedence = -a + b * (c + d)
stone="Blue"
print(get_stones(stone))

Loading…
Cancel
Save