Monday 10 June 2019

Java Concurrency Questions Part 1

Hello Everyone,

Welcome back to the interview questions series. Today I bring a bunch of questions related to Multithreading(Concurrency) i.e. part 1 of the multithreading questions .

1. Difference between semaphore and mutex?
2. Print odd and even number in sequence with using two threads in java?
3. Explain Fork Join Framework?
4. Explain Blocking queue in Java?
5. Explain Coundownlatch in Java?
6. Explain CyclicBarrier in Java?
7. What is volatile variable in Java?
8. What is Reentrant Lock in Java?
9. Explain Java Inter-thread Communication using Piped Streams?
10.   Explain Java ThreadLocal Variables?
11.   Object level Locking vs. Class level Locking in Java
12.   Can we make an Array or ArrayList volatile in Java?
13.   Why wait(), notify() and notifyAll() must be called from synchronized block or method in Java?
14.   How to Implement own Thread pool in java?
15.   What is PRODUCER CONSUMER problem?
16.   How to solve PRODUCER CONSUMER with wait and notify and notifyAll?
17.   How to solve PRODUCER CONSUMER with Semaphore?
18.   How to solve PRODUCER CONSUMER with Blocking Queue?
19.   What is a race condition?
20.   what is executor framework?
21.   What is Executor Service?
22.   What is the difference between Callable and Runnable?
23.   What is Synchronized block or method or class?
24.   What is Atomic Variable?
25.   What ThreadLocal?
26.   What is Object Level Locking ?
27.   What is class level locking?
28.   What is fairness?
29.   What is ReadWriteLock?
30.   What is the difference between Lock Interface and synchronized keyword?
31.   Difference between join and yield?
32.   Difference between sleep and wait?
33.   What is callable and future?

To be continued...

Happy Learning😊

No comments:

Post a Comment