Multiple Choice Questions & Answers on Multithreading
Multiple Choice Questions & Answers on Multithreading
1. Multithreading is a mechanism for splitting up a program into several parallel activities called _________
a) Methods
b) Objects
c) Classes
d) Threads
Answer: Classes
2. Multithreading on a single processor is possible with the help of _________
a) Threader
b) Scheduler
c) Method
d) Divider
Answer: Scheduler
3. An instance of class Buffer provides a threadsafe way of communication between ________
a) Actors
b) Objects
c) Locking
d) Buffer
Answer: Objects
4. Scheduler switch threads in ________
a) Multilevel queue scheduling
b) Priority Scheduling
c) Round robin fashion
d) Multilevel feedback queue scheduling
Answer: Round robin fashion
5. In ______ an object of type Thread in the namespace System.Threading represents and controls one thread.
a) . PY
b) .SAP
c) .NET
d) .EXE
Answer: .NET
6. The method will be executed once the thread’s ______ method is called.
a) EventBegin
b) EventStart
c) Begin
d) Start
Answer: Start
7. _______ makes it possible for two or more activities to execute in parallel on a single processor.
a) Multithreading
b) Threading
c) SingleThreading
d) Both Multithreading and SingleThreading
Answer: Multithreading
8. _______ method puts zero into the buffer.
a) HandlePut(object o)
b) HandletGet(object o)
c) HandletGet()
d) HandletPut()
Answer: HandlePut(object o)
9. What is the switching speed?
a) 60 times per second
b) 50 times per second
c) 55 times per second
d) 66 times per second
Answer: 50 times per second
10. HandlePut(object o) performs what?
a) Fixing values
b) Locking
c) Changing values
d) Unlocking
Answer: Unlocking
11. In HandlePut(object o), o represents?
a) Null
b) Zero
c) Empty
d) Origin
Answer: Null
12. Threads are
a) Lightweight process
b) Heavyweight process
c) Both a&b
d) One
Answer: Lightweight process
13. What is HandleGet() method function?
a) Current buffer state, with changing
b) Current buffer state, without changing
c) Previous buffer state, with changing
d) Previous buffer state, without changing
Answer: Current buffer state, without changing
14. What is the result for HandleGet()?
a) Null
b) Zero
c) Empty
d) Origin
Answer: Null
15. Command to make thread sleep?
a) Thread.Sleep
b) Thread_Sleep
c) ThreadSleep
d) Thread_sleep
Answer: Thread.Sleep
16. Each thread is a single stream of execution.
a) False
b) True
Answer: False
Comments
Post a Comment