in reply to a question on threads

I agree with davidrw that the specific problem you're seeing is probably just output buffering - that is, the print "foo" really does happen when you think it should it just doesn't look like it - but here's another issue to consider: what happens if the job to be done takes more than one second? Is it ok to have more than one thread performing this action at the same time?

Replies are listed 'Best First'.
Re^2: a question on threads
by thcsoft (Monk) on May 11, 2005 at 03:00 UTC
    yes, it will be ok, because each of them will have an individual set of data to act upon. nevertheless: thank you for the $| hint :)
    language is a virus from outer space.