Using join can control how much time will we wait for a specific thread to accomplish its execution. I am meeting with a new scenario, which is a little different. My requirement is that I want my main thread starts several threads at the same time, which will perform their individual tasks in a concurrent way and I also want to control main thread waiting each thread for at most some time in a concurrent way. I am wondering how to "join" several threads in a concurrent way (traditional join function can only join one thread)?
Thanks in advance,