c style thread creation in python
<p>Hi I am new to python and want to create multiple threads in a loop something like (in C style)</p>

<pre><code>for (;i &lt; 10; i++)
 thread[i]= pthread_create(&amp;thread[i],&amp;attr,func)
</code></pre>

<p>I am not sure how to do the same in python? Basically I want have that thread[] variable as global will create all thread at once and then will start then in once. I have written a similar python program that does it but I think having it in above style will be better.</p>

<pre><code>def thread_create(thread_number):
    command_string = "Thread-" + "%d" %thread_number
    thread = myThread(thread_number, command_string)
    thread.start()

# Start new Threads

for i in range(5):
    thread_create(i)
</code></pre>
