[Tutor] another ?-->if I created test.py how do I run test.py in hello.py and also how do I run it again in hello.py?

Daniel Yoo dyoo@hkn.EECS.Berkeley.EDU
Wed, 23 Aug 2000 12:31:44 -0700 (PDT)


On Wed, 23 Aug 2000, Charles Gruschow, Jr. wrote:

> another ?-->if I created test.py how do I run test.py in hello.py and
> also how do I run it again in hello.py?


I'm not quite sure if this is what you mean, but you can use

    execfile("test.py")

inside your hello.py file, and that'll execute test.py for you.  However,
this is something uncommon to me.  Can you explain to us why you want to
do this?