Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- # this is from The Python
- # Standard Library by example
- # ISBN13: 9780321767349
- import threading
- def worker():
- """thread worker function"""
- print 'Worker'
- return
- threads = []
- for i in range(5):
- t = threading.Thread(target=worker)
- threads.append(t)
- t.start()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement