peter at engcorp.com
Thu Jul 17 15:23:22 CEST 2003
thewrights at ozemail.com.au wrote:
> I have an application in which I want the users to be able to create python
> def f1():
> print "1-1"
> print "1-2"
> print "1-3"
> def f2():
> print "2-1"
> print "2-2"
> print "3-3"
> and when my application runs, I want to execute these functions in
> "lock-step", so that the output looks like:
I think the problem is underspecified. What do you mean by the quoted
phrase "lock-step"? Your example includes only simple print statements,
which generate output to sys.stdout. What are you really trying to
accomplish? Do you want individual bytecodes to be executed one at a
time from a series of functions? Do you want any output to be interlaced
on a line-by-line basis? Any call to any I/O routine? Need more detail.
More information about the Python-list