title: Code for Greatest Common Divisor in Python
body: <p>The greatest common divisor (GCD) of a and b is the largest number that divides both of them with no remainder.</p>
  
  <p>One way to find the GCD of two numbers is Euclid’s algorithm, which is based on the observation that if <code>r</code> is the remainder when <code>a</code> is divided by <code>b</code>, then <code>gcd(a, b) = gcd(b, r)</code>. As a base case, we can use <code>gcd(a, 0) = a</code>.</p>
  
  <p>Write a function called gcd that takes parameters <code>a</code> and <code>b</code> and returns their greatest common divisor.</p>