Skip to content

Commit d139a2c

Browse files
Fix syntax error by wrapping multiple exceptions in a tuple
1 parent f382f6a commit d139a2c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

maths/greatest_common_divisor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ def main():
7373
f"{greatest_common_divisor(num_1, num_2)}"
7474
)
7575
print(f"By iterative gcd({num_1}, {num_2}) = {gcd_by_iterative(num_1, num_2)}")
76-
except IndexError, ValueError:
76+
except (IndexError, ValueError):
7777
print("Wrong input")
7878

7979

0 commit comments

Comments
 (0)