编写程序,开发一个简单的计算器,输入两个数后可以进行加减乘除等运算...答:include<stdio.h>int main(void){int a,b,c=0;char d;scanf("%d",&a);scanf("%c",&d);scanf("%d",&b);switch(d){case'+':c=(a+b);break;case'-':c=(a-b);break;case'*':c=(a*b);break;case'/':c=(a/b);break;}printf("%d%c%d=%d\n",a,d,b,c)...
用switch语句编程设计一个简单的计算器程序答:include <stdio.h> int main( ){ double a, b;char op;scanf("%lf%c%lf", &a, &op, &b);switch (op){ case '+':printf("%lf + %lf = %lf\n", a, b, a + b);break;case '-':printf("%lf - %lf = %lf\n", a, b, a - b);break;case '*':printf("%...