|
5#
楼主 |
发表于 2017-8-10 17:38:52
|
只看该作者
[mw_shl_code=c,true]#include <stdio.h>
#include <stdlib.h>
int main()
{
long a,b,d;
char c;
scanf("%d %c %d",&a,&c,&b);
if(c=='+')
d=a+b;
if(c=='-')
d=a-b;
if(c=='*')
d=a*b;
if(c=='/')
d=a/b;
printf("%d%c%d=%d",a,c,b,d);
system("pause");
return 0;
}[/mw_shl_code] |
|