public class MainClass{
public static void main(String[] argv){
int y = 5;
int x = 2;
if (((x > 3) && (y < 2)) | doStuff()) {
System.out.println("true");
}
}
static boolean doStuff(){
return true;
}
}
public class MainClass{
public static void main(String[] argv){
int x = 3;
if (x = 5) { } // Won't compile because x is not a boolean!
}
}
|