Re: Python windows interactive.
- From: Tiefeng Wu <icebergwtf@xxxxxxxxxxxx>
- Date: Tue, 31 Oct 2006 09:49:18 +0800 (CST)
notejam wrote:
Thanks everyone for the help. I got a simple two line program to work
from a text file.
Can not figure out how to write more than one line in interpreter mode.
Is that all interpreter is good for, testing one liners? I have it
run the program everytime I hit return, and can not figure out how to
enter multiple lines of code. I can do multiple lines in text file, so
no problem, but I am jsut wondering can a program with 2 or more lines
be wrote from the interpreter mode?
I think for this purpose you can just define a function, like this:
... print "Hello"def test():
... print "World"
...
"Hello"test()
"World"
___________________________________________________________
雅虎免费邮箱-3.5G容量,20M附件
http://cn.mail.yahoo.com/
.
- Prev by Date: Re: ANN: Leo 4.4.2.1 final released
- Next by Date: Re: enumerate improvement proposal
- Previous by thread: Re: Python windows interactive.
- Next by thread: Serious wxPython Error while executing..
- Index(es):
Relevant Pages
|