input: Write a function to calculate the greatest common divisor of two numbers and return it. If one of the numbers is 0, return the other number as the GCD.
  assert gcd(0, 5)==5
  assert gcd(10, 20)==10
  assert gcd(24, 36)==12
  assert gcd(7, 13)==1
  assert gcd(0, 0)==0
output: def gcd(a, b):
      while b != 0:
          a, b = b, a % b
      return a