16
edits
Changes
→Cleaning up code formatting and adding thread creation example for c++11 thread library
t2.join();
t3.join();
} //Creating thread 1://Creating thread 2://Creating thread 3://Hello from thread 3//Hello from thread 1//Hello from thread 2</syntaxhighlight>
The code above gives a simple example on how threads are created and joined back to the parent thread in the end.