RosettaCodeData/Task/Concurrent-computing/Python/concurrent-computing-2.py

10 lines
243 B
Python
Raw Normal View History

2013-04-10 16:57:12 -07:00
import threading
import random
def echo(text):
print(text)
threading.Timer(random.random(), echo, ("Enjoy",)).start()
threading.Timer(random.random(), echo, ("Rosetta",)).start()
threading.Timer(random.random(), echo, ("Code",)).start()