Exam Tiger
APTITUDE TESTS - MENTAL ABILITY - SOLVED OBJECTIVE MCQ SETS - QUESTION ANSWER - PDF STUDY MATERIALS - SHORTCUT TIPS

Java Interview - Selected Questions → Page 3

Java Interview - Selected Questions solved MCQ sets : Java MCQ : Here you are going to get a selected list of multiple choice questions (MCQ) on JAVA that will give you an idea of basic concept of object oriented programming with Java language. These section include q...READ MORE


INSTRUCTION: CLICK ON THE OPTION (A, B, C, D) TO SELECT IT AS YOUR ANSWER.


Q. What is garbage collection in the context of Java?
A.
Java deletes all unused java files on the system.
B.
Memory used by the object with no reference is automatically reclaimed.

C.
The JVM cleans output of Java program with error.
D.
Any unused package in a program automatically gets deleted.

Show Answer
Q. Which one is a template for creating different objects ?
A.
An Array
B.
A class

C.
Interface
D.
Method

Show Answer
Q. Which symbol is used to contain the values of automatically initialized arrays?
A.
Brackets
B.
Braces

C.
Parentheses
D.
Comma

Show Answer
Q. Which one is true about a constructor ?
A.
A constructor must have the same name as the class it is declared within.
B.
A constructor is used to create objects.

C.
A constructor may be declared private
D.
All of the above

Show Answer
Q. Which of these operators is used to allocate memory to array variable in Java?
A.
alloc
B.
malloc

C.
new malloc
D.
new

Show Answer

Advertisement


eXTReMe Tracker