JAVA 25

COEP
Lets Crack Online Exam

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

Subject: JAVA 25

Part 25: List for questions and answers of JAVA

 

Q1. Which of these class is used to make a thread?

a) String

b) System

c) Thread

d) Runnable

 

Q2. Which of these interface is implemented by Thread class?

a) Runnable

b) Connections

c) Set

d) MapConnections

 

Q3. Which function of pre defined class Thread is used to check weather current thread being checked is still running?

a) isAlive()

b) Join()

c) isRunning()

d) Alive()

 

Q4. Which methods are utilized to control the access to an object in multi threaded programming

a) Asynchronized methods

b) Synchronized methods

c) Serialized methods

d) None of above

 

Q5. Which of the following is used to force each thread to reconcile its working copy of a variable with the master copy in main memory?

a) synchronized

b) transient

c) volatile

d) native

 

Q6. What is multithreaded programming?

a) It’s a process in which two different processes run simultaneously

b) It’s a process in which two or more parts of same process run simultaneously

c) Its a process in which many different process are able to access same information

d) Its a process in which a single process can access information from many sources 

 

Q7. Which of these are types of multitasking?

a) Process based

b) Thread based

c) Process and Thread based

d) None of the mentioned

 

Q8. Which of these packages contain all the Java’s built in exceptions?

a) java.io

b) java.util

c) java.lang

d) java.net

 

Q9. Thread priority in Java is?

a) Integer

b) Float

c) double

d) long

 

Q10. What will happen if two thread of same priority are called to be processed simultaneously?

a) Any one will be executed first lexographically

b) Both of them will be executed simultaneously

c) None of them will be executed

d) It is dependent on the operating system

 

Q11. Which of these statements is incorrect?

a) By multithreading CPU’s idle time is minimized, and we can take maximum use of it

b) By multitasking CPU’s idle time is minimized, and we can take maximum use of it

c) Two thread in Java can have same priority

d) A thread can exist only in two states, running and blocked

 

Q12. What is the name of the method used to start a thread execution?

a) init()

b) start();

c) run();

d) resume(); 

 

Q13. What is multithreaded programming?

a) It’s a process in which two different processes run simultaneously

b) It’s a process in which two or more parts of same process run simultaneously

c) Its a process in which many different process are able to access same information

d) Its a process in which a single process can access information from many sources

 

Q14. Which of these are types of multitasking?

a) Process based

b) Thread based

c) Process and Thread based

d) None of the mentioned

 

Q15. Which of these packages contain all the Java’s built in exceptions?

a) java.io

b) java.util

c) java.lang

d) java.net

 

Q16. Thread priority in Java is?

a) Integer

b) Float

c) double

d) long

 

Q17. What will happen if two thread of same priority are called to be processed simultaneously?

a) Any one will be executed first lexographically

b) Both of them will be executed simultaneously

c) None of them will be executed

d) It is dependent on the operating system

 

Q18. Which of these statements is incorrect?

a) By multithreading CPU’s idle time is minimized, and we can take maximum use of it

b) By multitasking CPU’s idle time is minimized, and we can take maximum use of it

c) Two thread in Java can have same priority

d) A thread can exist only in two states, running and blocked 

 

Q19. Which of these data type is returned by every method of OutputStream?

a) int

b) float

c) byte

d) None of the mentioned

 

Q20. Which of these is a method to clear all the data present in output buffers?

a) clear()

b) flush()

c) fflush()

d) close() 

 

Part 25: List for questions and answers of JAVA

 

Q1. Answer: c

 

Q2. Answer: a

 

Q3. Answer: a

 

Q4. Answer: b

 

Q5. Answer: c

 

Q6. Answer: b

 

Q7. Answer: c

 

Q8. Answer: c

 

Q9. Answer: a

 

Q10. Answer: d

 

Q11. Answer: d

 

Q12. Answer: b

 

Q13. Answer: b

 

Q14. Answer: c

 

Q15. Answer: c

 

Q16. Answer: a

 

Q17. Answer: d

 

Q18. Answer: d

 

Q19. Answer: d

 

Q20. Answer: b