#include <bits/stdc++.h>
using namespace std;
int main() {
int a,b,c,ip=1;
cin>>a>>b>>c;
if((a && b)==c){
cout<<"AND"<<endl;
ip=0;
}
if((a || b)==c){
cout<<"OR"<<endl;
ip=0;
}
if((a ^ b)==c){
cout<<"XOR"<<endl;
ip=0;
}
if(ip){
cout<<"IMPOSSIBLE";
}
return 0;
}
#include
using namespace std;int main() {
int a,b,c,ip=1;
cin>>a>>b>>c;
if((a && b)==c){
cout<<"AND"< ip=0;
}
if((a || b)==c){
cout<<"OR"< ip=0;
}
if((a ^ b)==c){
cout<<"XOR"< ip=0;
}
if(ip){
cout<<"IMPOSSIBLE";
}
return 0;
}
試試看如果a或b>1,將a或b設為1