so - once I get to the python command prompt, I should be able to open
.py files - right?
and am I doing that incorrectly or is that, from within python you
always have to import files? , or where can I get more information on
how to do this?
or is the point that you are making is that the book reference I
described from what you can see indicates that I should be calling the
files using the cmd.exe terminal, not the python terminal.
I'd like to be able to just run the files through the python terminal,
but you are right, I'm definitely confused as I grew up on windows not
dos and am fairly new to programming in general.
Once I get my environment straight, which I hope to do today - I can't
wait to learn this stuff.
there is no way I can move on learning this stuff because the next part
of the reference manual requires me to do the following:
"The interactive Python shell provides us with a convenient way to test
our functions. We can use the import statement to bring the functions
we have defined in a script into the interpreter session. To see how
this
works, assume the print_twice function is defined in a script
named chap03.py. We can now test it interactively by
importing it into our Python shell session:
>>> from chap03 import *
>>> print_twice('Spam')
Spam Spam
>>> print_twice(5)
5 5
>>> print_twice(3.14159)
3.14159 3.14159"
I can't import the functions because my environment is screwed up or I'm
doing something wrong.
Thanks!!!!!
--- In PhillyPug@yahoogroups.com, Erik Osheim <erik@...> wrote:
>
> So, I've never used IDLE or Windows. That said, I think you are
getting
> confused between the Python shell (which uses ">>>" as the prompt, and
> probably runs from within IDLE) and the OS shell (I think it's called
> cmd.exe or something).
>
> If you open a cmd.exe terminal (which looks like the old DOS
> command-line) you should be able to type python and see something like
> the following:
>
> Python 2.6.2 (r262:71600, Jun 1 2009, 12:31:36)
> [GCC 4.3.3] on linux2
> Type "help", "copyright", "credits" or "license" for more
information.
> >>>
>
> Only in your case, it will probably say something about Windows.
>
> Hope this helps.
>
> -- Erik
>