关于调用函数的问题,请各位指点一番,谢谢!
/* Note:Your choice is C IDE */#include "stdio.h"
void main()
{ int n,a,b,c;
printf("请输入两个整数(逗号隔开):");
scanf("%d,%d",&a,&b);
n=b;
c=a%b;
void print_1();
void print_2();
print_1();
print_2();
return 0;
}
void print_1()
{
while(c!=0)
{
a=b;
b=c;
c=a%b;
}
printf("\n最大公约数是:%d\n",b);
}
void print_2()
{ printf("\n最大公倍数是:%d\n",a*n/b);
}