Run ID Author Problem Lang Verdict Score Time Memory Code Length Submit Time
20025 桑迪 计算表达式 C++ No Test Data 0 0 MS 0 KB 253 2021-05-27 22:07:33

Tests(0/0):


#include<iostream> #include<cstdio> using namespace std; int main() { int a,b; char ch; cin>>a; while(cin>>ch){ cin>>b; switch(ch){ case '+':a+=b;break; case '-':a-=b;break; case '*':a*=b; } } cout<<a; return 0; }