fork download
  1. class GreaterNumber
  2. {
  3. public static void main(String arg[])
  4.  
  5. {
  6. boolean b;
  7. int weight=45;
  8. b=weight>50;
  9. System.out.println(b);
  10. }
  11. }
Success #stdin #stdout 0.09s 47080KB
stdin
Find the output of the following code:
class Tutorial {
String tutName;
int tutNo;
public static void main(String[] args)
 {
Tutorial tut = new Tutorial();
Tutorial tut1= new Tutorial();
tut.tutName="Java";
tut.tutNo=2;
System.out.print("Tutorial Number " + tut.tutNo + "is " +tut.tutName);
System.out.print("Tutorial Number " + tut1.tutNo + "is " +tut1.tutName);
}
}
stdout
false