What is the problem with this? code why it is not running?

int n1,n2,c;
char ch;
cin >>ch;
while(ch!='X'||ch!='x'){
 if(ch=='+'){
		cin>>n1>>n2;
		c=n1+n2;
		cout<<c<<endl;
	}
	else if(ch=='-'){
		cin>>n1>>n2;
		c=n1-n2;
		cout<<c<<endl;

	}
	else if(ch=='*'){
		cin>>n1>>n2;
		c=n1*n2;
		cout<<c<<endl;
	}
	else if(ch=='/'){
		cin>>n1>>n2;
		c=n1/n2;
		cout<<c<<endl;
	}
	else if(ch=='%'){
		cin>>n1>>n2;
		c=n1%n2;
		cout<<c<<endl;
	}
	else{
		cout<<"invalid operation"<<endl;
	}
	cin>>ch;
}
return 0;

}

The condition in the while loop should be (ch != 'X' && ch != 'x') .

You can refer my code as well

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.