Threading
Matt
matt.mailinglists at gmail.com
Fri Jan 24 15:33:46 EST 2020
I am using this example for threading in Python:
from threading import Thread
def start_test( address, port ):
print address, port
sleep(1)
for line in big_list:
t = Thread(target=start_test, args=(line, 80))
t.start()
But say big_list has thousands of items and I only want to have a
maximum of 10 threads open. How do work my way through the big_list
with only 10 threads for example?
More information about the Python-list
mailing list