java - Bad operand for binary operator? -


i have no idea wrong, beginner. appreciated.

if(room.contains((targetroom1) || (targetroom2) && targetday)){

the error code bad operand types binary operator '&&' first type: java.lang.string; second type: java.lang.string

the error tells targetroom2 , targetday not booleans, cannot use &&.

i guess want test like:

if(room.contains(targetroom1) || room.contains(targetroom2) && (targetday == queryday)){ 

Comments

Popular posts from this blog

asp.net mvc - SSO between MVCForum and Umbraco7 -

Python Tkinter keyboard using bind -

ubuntu - Selenium Node Not Connecting to Hub, Not Opening Port -