gcd

int gcd(int a,int b)
{
  if(b) while((a%=b)&&(b%=a));
  return a+b;
}
原文地址:https://www.cnblogs.com/zzqdeco/p/13434816.html