Added example of how to create treads.