Sounds like a neat problem to do. We aren't allowed to give anyone homework help unless they show some effort. If you do, we will be more than happy to help out. In the mean time, look up synchronizing threads. I've done a problem similar to this where two people share a bank account, so if you show a little effort I can surely help you.
Reputation Points: 113
Solved Threads: 19
Postaholic
Offline 2,108 posts
since Jun 2004