Java concepts and its programming – MCQs

80 questions. Click to practice.

Correct options are highlighted when revealed.

1.In JDBC, which driver is commonly referred to as the thin driver?

2.What is the least number of threads that a program must have?

3.Which method is used to reactivate a suspended thread?

4.Which of the following correctly describes the nature of Java's byte, short, int, and long data types?

5.Which type of method cannot be overridden in Java?

6.Which package in Java contains the gc() method?

7.What is the term for transforming a primitive data type into its equivalent wrapper class object?

8.In Java programming, what does the term 'true' represent?

9.What type of software is HotJava classified as?

10.What does the term 'JAR' stand for in Java?

11.Which access level modifier allows a method in a class to be accessible only by other classes within the same package?

12.What does the term 'javah' refer to?

13.Which function in the Applet class is responsible for rendering the output of the applet on the display?

14.Which command is utilized to compile a Java source file?

15.What is the size of the int data type in Java?

16.Which of the following methods is called a single time during its lifecycle?

17.What will be printed when the following Java program is executed? public class Test { public static void main(String[] args) { int i = 010; int j = 07; System.out.println(i); System.out.println(j); } }

18.If a class is declared as public and contains a protected method, which of the following statements accurately describes the accessibility of that protected method?

19.What is the total number of transaction isolation levels specified in the java.sql.Connection interface?

20.What does the acronym JIT stand for?