c语言计算机程序
计算机代码
代码
#include <stdio.h>
int main(){char cp;int a, b;scanf("%d %c %d", &a, &cp, &b);if (cp == ‘-’)printf("%d", a - b);else if(cp == ‘+’)printf("%d", a + b);else if (cp == ‘*’)printf("%d", a * b);else if (cp == ‘%’)printf("%d", a % b);return 0;}
不能除法计算机。
03-14
1008
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
06-08
3169
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
05-09
1245
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
07-07
763
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)