Java Interview Questions

Q76. ______ is a group of related data items that share a common name with same data type
(a) String
(b) Array
(c) Parameter
(d) Arguments

Q77. Which one of the following is false
(a) type arrayname[];
(b) arrayname [] type;
(c) type [] arrayname;
(d) None of the above

Q78. Which of the following is not a wrapper class
(a) Integer
(b) Byte
(c) Random
(d) Short

Q79. Which of the following is false
(a) It is convenient to use vectors to store objects
(b) Vector can be used to store a list of objects that may vary in size
(c) Vector ia a StringBuffer
(d) We can add and delete objects from the list as and when required

Q80. We can use_________ to convert primitive data types to wrapper class types automatically
(a) Auto boxing
(b) Unboxing
(c) Annotations
(d) Both A and B

Q81. ______________ method is used to convert primitive numbers to object numbers in wrapper classes
(a) String() Method
(b) Constructor Methods
(c) Parsing Method
(d) None of the above

Q82. ________ gives the number of objects present
(a) list.size()
(b) list.copyInto(array)
(c) list.removeElement(item)
(d) Both A and B

Q83. Which are true
(a) An interface can sub interfaced from other interface
(b) Interface support extending
(c) Interface can’t support extending
(d) Both A and B

Q84. _________ package is classes for networking
(a) java.io
(b) java.net
(c) java.awt
(d) java.applet

Q85. Dead state can be compared with ______ method of applets
(a) stop()
(b) paint()
(c) destroy()
(d) init()

Q86. ________ method is used to find out that a thread is still running or no
(a) Alive()
(b) CheckRun()
(c) isAlive()
(d) Run()

Q87. Default value of priority variable MIN_PRIORITY
(a) 1
(b) 10
(c) 100
(d) 1000

Q88. Default value of priority variable MAX_PRIORITY
(a) 5
(b) 10
(c) 50
(d) 100

Q89. Dividing an integer by zero is a ______error
(a) Compile
(b) Syntax
(c) Runtime
(d) Logic

Q90. An exception is a condition that is caused by a ________ error in the program
(a) Compile
(b) Execution
(c) Runtime
(d) Syntax


1 2 3 4 5 6 7 8