JAVA QUIZ
1 .
Object-Oriented Programming means ...  

Correct Answer : Option (A)

Writing an algorithm before writing your program and having a test plan 
  Show Answer
2 .
What is an Applet ?

Correct Answer : Option (B)

A Java program that is run through a web browser
  Show Answer
3 .
Which statement is true for method overloading?

Correct Answer : Option (B)

Multiple methods in same class, same name and return type, different parameters
  Show Answer
4 .
What is the main function of any variable ?

Correct Answer : Option (C)

To keep track of data in the memory of the computer 
  Show Answer
5 .
What is the replacement of joda time library in java 8?

Correct Answer : Option (B)

java.time (JSR-310)
  Show Answer
6 .
What will be printed?
int i = 255;
byte b = (byte) i;
System.out.println(b);

Correct Answer : Option (D)

-1
  Show Answer
7 .
How is Date stored in database?

Correct Answer : Option (A)

java.sql.Date
  Show Answer
8 .
What is the output of this program?
class average {
        public static void main(String args[])
        {
            double num[] = {5.5, 10.1, 11, 12.8, 56.9, 2.5};
            double result;
            result = 0;
            for (int i = 0; i < 6; ++i) 
                result = result + num[i];
	    System.out.print(result/6);
 
        } 
    }​

Correct Answer : Option (C)

16.46666666666667
  Show Answer
9 .
What will be the output of the program?
class Bitwise 
{
    public static void main(String [] args) 
    {
        int x = 11 & 9;
        int y = x ^ 3;
        System.out.println( y | 12 );
    }
}​

Correct Answer : Option (D)

14 
  Show Answer
10 .
Which class can access all public and protected methods and fields of its super class?

Correct Answer : Option (C)

sub-class 
  Show Answer