91.
What will be the output of the following Java program, Command line exceution is done as - "java Output This is a command Line"?
class Output 
{
    public static void main(String args[]) 
    {
        System.out.print(args[3]);
    }
}

92.
What will be the output of the following Java code snippet run as $ java Demo -length 512 -breadth 2 -h 3?
class Demo {
    @Parameter(names={"--length"})
    int length;
 
    @Parameter(names={"--breadth"})
    int breadth;
 
    @Parameter(names={"--height","-h"})
    int height;
 
    public static void main(String args[]) 
    {
        Demo demo = new Demo();
        new JCommander(demo, args);
        demo.run();
    }
 
    public void run() 
    {
        System.out.println(length+" "+ breadth+" "+height);
    }
}

93.
Which of the following statements are incorrect?

94.
What will be the output of the following Java program?
class string_demo 
{
    public static void main(String args[])
    {
        String obj = "I" + "like" + "Java";   
        System.out.println(obj);     
    }
}

95.
What will be the output of the following Java program?
class Output 
{
    static void main(String args[]) 
    {    
         int x , y = 1;
         x = 10;
         if(x != 10 && x / 0 == 0)
             System.out.println(y);
         else
             System.out.println(++y);
    } 
}

100.
Which of these statement is incorrect?

Read More Section(Miscellaneous in Java)

Each Section contains maximum 100 MCQs question on Miscellaneous in Java. To get more questions visit other sections.