In a barber shop there are 2 doors. customer come in 1
door, leave in other. minimum # of chairs. barber spend his
life in cutting. always barber can cut 1 customer. few
chairs in the shop. if barber busy customer waits, if
chairs full, customer leave. if no customer, barber sleeps.
treat barber and customer as 2 threads. you can use
Semaphore class with arrive and depart and count as
parameter.
No Answer is Posted For this Question
Be the First to Post Answer
What is loose coupling in java?
I am new to jsf rich faces. I am using rich faces datatable rich:datatable. On entering the value, values get filtered in table. Now how can i get the value i selected in backing bean?
What is data encapsulation?
What is jsr in java?
What do you understand by a variable?
How do javabeans work?
What is the difference between Logical Parallelism and Physical Parallelism?
What about javascript? : java security
Why is struts used in java?
What is web container in java?
What is flatmap in java8?
What is an api in java?