switch(symbol){ case '+': cout<<a+b<<endl; break; case '-': cout<<a-b<<endl; break; case '*': cout<<a*b<<endl; break; case '/': cout<<a/b<<endl; break;
關鍵code