meeta gaur wrote:I thought i have created three different threads
Yes.
and they use their own lock for synchronization
Yes
and operating on their own StringBuffer object rather than a shared object.
No. How many times do you make a StringBuffer? What line(s) of code make the StringBuffers?
And because the third statement is false the fact that the first and second are true breaks the code.