JAVA 4

COEP
Lets Crack Online Exam

IT Interview Exam Questions: JAVA 4 (IT Campus Placement)

Subject: JAVA 4

Part 4: List for questions and answers of JAVA

 

Q1. The method cant be overridden

a) final

b) abstract

c) public

d) private

 

Q2. Hot java is

a) web browser

b) java version

c) IDE

d) none

 

Q3. javah stands for

a) compiler

b) Interpreter

c) Header file

d) debugger

 

Q4. Main method parameter has which type of data type

a) String

b) Int

c) char

d) double

 

Q5. How many keywords are available in java

a) 48

b) 35

c) 32

d) 52

 

Q6. Smallest individual unit in java program is known as

a) String

b) Literal

c) Token

d) operator 

 

Q7. What is return type of execute() method?

a) Action forward

b) void

c) String

d) int

 

Q8. A thread becomes runnable when you call

a) start()

b) run()

c) init()

d) none

 

Q9. struts work on

a) model 1

b) model2(MVC)

c) none of these

d) model3

 

Q10. Hibernate is ?

a) Object oriented mapping

b) database

c) java API

d) java compiler

 

Q11. tool used to execute java code

a) javac

b) java

c) javap

d) javal

 

Q12. single line comment start with

a) /*

b) //

c) /

d) none

 

Q13. process of writing the state of object into byte stream

a) Deserialisation

b) Externlisation

c) serialisation

d) print 

 

Q14. marker interface

a) having body

b) having no body

c) both

d) none

 

Q15. Choose one marker interface

a) serializable

b) iterator

c) collection

d) none

 

Q16. What allows the programmer to destroy an object x?

a) Only the garbage collection system can destroy an object

b) X.delete

c) X.destroy

d) none

 

Q17. Which statement is true?

a) Objects that can be reached from a live thread will never be garbage collected

b) Programs will not run out of memory

c) Objects that will never again be used are eligible for garbage collection

d) Objects that are referred to by other objects will never be garbage collected

 

Q18. Which statement is true?

a) All objects that are eligible for garbage collection will be garbage collected by the garbage collector

b Objects with at least one reference will never be garbage collected

c) Objects from a class with the finalize() method overridden will never be garbage collected

d) Objects instantiated within anonymous inner classes are placed in the garbage collectible heap

 

Q19. Which class does not override the equals() and hashCode() methods, inheriting them directly from class Object?

a) java.lang.String

b) java.lang.StringBuffer

c) java.lang.Double

d) java.lang.Character 

 

Q20. Which interface does java.util.Hashtable implement?

a) Java.util.Map

b) Java.util.List

c) Java.util.Hashtable

d) None 

 

Part 4: List for questions and answers of JAVA

 

Q1. Answer: a

 

Q2. Answer: a

 

Q3. Answer: c

 

Q4. Answer: a

 

Q5. Answer: a

 

Q6. Answer: c

 

Q7. Answer: a

 

Q8. Answer: a

 

Q9. Answer: c

 

Q10. Answer: a

 

Q11. Answer: b

 

Q12. Answer: a

 

Q13. Answer:

 

Q14. Answer: b

 

Q15. Answer: a

 

Q16. Answer: a

 

Q17. Answer: a

 

Q18. Answer: d

 

Q19. Answer: b

 

Q20. Answer: a