A program to show to retrun from a thread function and collect the retruned value in the the main thread.