递归 def gcd(a, b): if b == 0: return a a, b = b, a % b return gcd(a, b) 循环 def gcd(a, b): while b: a, b = b, a % b return a 证明 todo