printf("最大值是&d",c)
#include<stdio.h> //是include而不是includ int main() { int a,b,c; //不要忘了分号“;” printf("请输入两个数:\n"); scanf("%d,%d",&a,&b); if(a>=b) c=a; printf("最大值是%d\n",c);//这里是用%,而不是&,还有逗号“,”分号“;”不能用中文的 else printf("%d\n",b); return 0; }
# include<stdio.h> int main() { int a,b,c; printf("请输入里两个数:\n"); scanf("%d%d",&a,&b); if(a>b) { printf("最大值是%d",a); } else { printf("%d",b); } return 0; }