Whats wrong in it

#include
using namespace std;
int main() {
char ch;
int n,m;

cin >> ch;
    
if(ch=='x' || ch=='X'){
    return 0;
}


do {
    
    if(ch=='x' || ch=='X'){
    return 0;
    }
    
    switch (ch) {
        case '+': cin >>n>>m;
        cout << n+m << endl;
        break;

        case '-': cin >>n>>m;
        cout << n-m<< endl;
        break;

        case '*': cin >>n>>m;
        cout << n*m<< endl;
        break;

        case '/': cin >>n>>m;
        cout << n/m<< endl;
        break;

        default : cout << "Invalid operation"<< endl;
        break;
    }
    
    cin >> ch;

}while(ch!='x' || ch!='X');
return 0;

}

Hey @Sahilgohrisg, when you import a library you need to specify its name so, in the first line instead of just writing “#include” you would have to write “#include<bits/stdc++.h>” or “#include” and in the default case you should print “Invalid operation. Try again.” not just “Invalid operation”.

#include
using namespace std;
int main() {
char ch;
int n,m;

cin >> ch;

if(ch==‘x’ || ch==‘X’){
return 0;
}

do {

if(ch=='x' || ch=='X'){
return 0;
}

switch (ch) {
    case '+': cin >>n>>m;
    cout << n+m << endl;
    break;

    case '-': cin >>n>>m;
    cout << n-m<< endl;
    break;

    case '*': cin >>n>>m;
    cout << n*m<< endl;
    break;

    case '/': cin >>n>>m;
    cout << n/m<< endl;
    break;

    default : cout << "Invalid operation"<< endl;
    break;
}

cin >> ch;

}while(ch!=‘x’ || ch!=‘X’);
return 0;
}

with this also only first two test case are passing

default case is wrong, it should be cout << “Invalid operation. Try again.”, please read the question carefully.