← Quiz: Java Multithreading: all 10 questions
Quiz: Java Multithreading · Question 2 of 10
What do all threads of a process share?
What do all threads of a process share?
- A.Their stacks
- B.The heap
- C.Their program counters
- D.Nothing
Answer & explanation
Correct answer: The heap
Each thread has its own stack, but the heap (objects) is shared.
Can you get the rest right without peeking?
Take the timed Quiz: Java Multithreading quiz free. Pass it to earn XP and count towards your certificate.
Start the quiz →