# This line, and all lines starting with a #, are comments.
# They are ignored by the interpreter.
# WARNING: this program has several errors!
'''
Sometimes you may see multi-line comments formatted like this,
beginning and ending with three single quote characters. Technically
they aren't quite comments, but that's how they're usually used.
'''
# Purpose: compute the greatest common divisor (GCD) of two numbers.
def main():
# Inputs: two positive integers (whole numbers) a and b.
# Outputs: the GCD of a and b
a = input("Please enter a first number: ")
b = input("Please enter another number: ")
# 1. Repeat as long as b is not zero:
while b != 0:
# 1.1. If a > b, then set a <- (a - b)
if a > b:
a = a - b
# 1.2. Otherwise, set b <- (b - a)
else:
b = b - b
# 2. Output a as the answer.
print("The GCM of your numbers is", a)
main()