#euclid.py
"""Lecture example to demonstrate while-loop in Euclid's Algorithm for finding
the greatest common factor of two positive integers.
Trivia: it is one of the oldest recorded algorithms (~200B.C.)
"""

a= 8
b= 12
while a!=b:
    if a>b:
        a= a - b
    else:
        b= b - a
print(a)
