mirror of
https://github.com/TheAlgorithms/Python.git
synced 2025-07-05 01:09:40 +08:00
all valid python 3
This commit is contained in:
@ -37,7 +37,7 @@ def is_balanced(S):
|
||||
|
||||
def main():
|
||||
|
||||
S = raw_input("Enter sequence of brackets: ")
|
||||
S = input("Enter sequence of brackets: ")
|
||||
|
||||
if is_balanced(S):
|
||||
print((S, "is balanced"))
|
||||
|
@ -19,7 +19,7 @@ def moveDisk(fp,tp):
|
||||
print(('moving disk from', fp, 'to', tp))
|
||||
|
||||
def main():
|
||||
height = int(raw_input('Height of hanoi: '))
|
||||
height = int(input('Height of hanoi: '))
|
||||
moveTower(height, 'A', 'B', 'C')
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
Reference in New Issue
Block a user