30th
Jan
Jan

Java MCQ
- Admin
- 30th Jan, 2023
- 925 Followers
Java MCQ Questions
Take Java MCQ Test to Test Your Knowledge
Practice here the top 50+ Java MCQ Questions, which are very popular & cover the latest and important topics of Java Programming Language. So practice these questions to check your final preparation for Java Exams, Interviews & Placement Drives. apart from this, you can also download Java MCQ PDF completely free.
Java MCQ Questions
1) Java was originally developed by -
2) Which of the following function is used to find and fix bugs in the Java programs?
3) _________is the return type of the hashCode() method in the Object class?
4) Which of the following option is a valid long literal?
5) A single read/write operation performs _____ In character stream I/O.
Download Free : Java MCQ PDF
6) ______________ is the order of variables in Enum?
7) Which of the following method returns the elements of Enum class?
8) Which of the following is the limitation of toString() method of BigDecimal?
9) BigDecimal is a part of___________ package?
11) How to get UTC time using Java?
12) Literals in java must be appended by -
13) Which of the following is Truncation is Java?
14) Arrays are _______ in Java?
15) _____ legally declare, construct and initialize an array
Download Free: Core Java Interview Questions PDF
16) When you passed an array to a method, the method receives -
17) An attempt to add null key to a TreeMap will result in
18) Which of the following keywords is used to define packages in Java?
19) _________is the correct way of importing an entire package ‘pkg’.
20) Which of the following method of class String is used to obtain length of String object?
21) What is the range of short data type in Java?
22) Which data type value is returned by all transcendental math functions?
23) Which of these coding types is used for data type characters in Java?
24) Which one is a valid declaration of a boolean?
25) Which of the following method returns the elements of Enum class?
26) BigDecimal is a part of ............... package.
27) How to format date from one form to another?
28) Which of these is long data type literal?
29) Which of these is an incorrect array declaration?
30) Modulus operator, %, can be applied to which of these?
31) Which of the following is the correct statement to return java?
32) Which of the following data type value is returned by all transcendental math functions?
33) A method is defined in a class as ...........
34) What will be the output of following code?
35) Which of the following are the valid array declarations?
36) What will be the output of the following code?
37) Which of the following are not wrapper classes?
38) Do Java Identifiers must start with a letter, dollar sign ($), or underscore (_)?
39) What is the result of attempting to compile and run the following program?
40) The length of an Array ‘abc’ can be found using .............
41) ................ stops MultiThreading.
42) What is the value of String s in the following code?
43) What is the output of following code?
44) Which of the following is data structure which stores the key/value pairs in the List?
45) Collections are used to store, retrieve and manipulate data and to transmit data from one method to another.
46) What is the output of following code?
47) Which of the following are not legal identifiers in Java ?
48) Identify the super class of all errors and exceptions in the Java language.
49) Which of the following interface provides methods for retrieving data returned by an SQL statement?
50) Which of the following performs iteration in either direction, modify the list during iteration, and obtain the iterator's current position in the list?
51) A class that is defined with a parameter of a type is called a ...........
52) Which of the following method of Connection interface returns the instance of CallableStatement?
53) List is used for collection of elements with duplicates.
54) Which of the followoing interface is used to order the objects of user-defined class in java?
55) What will be the output of the folloiwng code?
56) When Subclass type refers to the object of Parent class, it is known as ..............
57) What is the result of following code?
58) Which of the following keyword allows the main() method to be called, without needing to create an instance of the class?
59) Which option represents a string that can be modified?
60) Polymorphism is the capability of a method to do different things based on the object that is acting upon it.
Leave A Comment :
Valid name is required.
Valid name is required.
Valid email id is required.