Semaphore implementation

sonu2die4's Avatar, Join Date: Feb 2007
Newbie Member
Hello,
I want to know how to implement semaphore without the use of while or any if statement
The Problem is
Thread A , B , C they all want to output the result at the same time
A wants ot print 'A'
B wants to print 'B'
C wants to print 'C'
the output must be 'ABC'. I do not know how to do this.Please help me with the same
Regards
Sonu
shabbir's Avatar, Join Date: Jul 2004
Go4Expert Founder
Start the B thread from A and C from B and the job is done.
sonu2die4's Avatar, Join Date: Feb 2007
Newbie Member
but how would i implement a semaphore for that
shabbir's Avatar, Join Date: Jul 2004
Go4Expert Founder
But why do you need semaphore?