
#include
using namespace std;
int main(){
int a, b, c;
cout <<"輸入a b c : "; bool found=false; scanf("%d %d %d", &a, &b, &c); if (a>0)a=1;
else a=0;
if(b>0)b=1;
else b=0;
if((a&b)==c){
cout<<"AND"<<endl;
found=true;
}
if((a|b)==c){
cout<<"OR"<<endl;
found=true;
}
if((a^b)==c){
cout<<"XOR"<<endl;
found=true;
}
if(!found)cout<<"IMPOSSIBLE"<<endl;
}
