char o = '+'; //Or some other character if (o == '%' || o == '/' || o == '*' || o == '+' || o == '-') { //Do something //... }