#include <stdio.h> int main(){ int numbers,i,a, b; double num; char opeart; scanf("%d", &numbers); for ( i = 0; i < numbers; i++) { getchar(); scanf("%c%d%d", &opeart,&a,&b); switch (opeart) { case '+':printf("%d ", a + b); break; case '-':printf("%d ", a - b); break; case '*':printf("%d ", a * b); break; case '/':a%b?printf("%.2lf ",a*1.0/b):printf("%d ",a/b); break; } } return 0; }