最大公约数 不知道哪里出了问题


#include <stdio.h>
#include <stdlib.h>

int gcd(int a,int b)

 {
     if(a%b==0)
     return b;
         else;
         return gcd(b,a%b);
 }
int main()
{
   int a,b;
   scanf("%d,%d",&a,&b);
   if(a>=b)
   printf("最大公约数为:%d\n",gcd(a,b));
   else printf("最大公约数为:%d\n",gcd(b,a));
    return 0;
}

else后面多了个分号;

除过楼上说的else后面多了个 ; ,其他没有问题,你输入的时候:
应该是:10,4 用逗号隔开,别用空格