#include using namespace std; int main() { //students enters a simple math //expression 6 + 7 // 8 - 2 // 5 * 3 int x, y; char op; cout << "enter arithmetic expression:\n\n"; cin >> x >> op >> y; cout << x << ' ' << op << ' ' << y << ' ' << "= "; switch (op) { case '+': cout << x + y; break; case '-': cout << x - y; break; case '*': cout << x * y; break; default: cout << "ILLEGAL OPERATOR!"; } cout << endl << endl; }