[Tutor] Newbie question

Glen Wheeler wheelege@tsn.cc
Fri, 27 Apr 2001 03:02:38 +1000


> Hello, everyone. I just joined this list. I'm an instructor at a private
> boarding school and I'm looking at implementing Python as the introductory
> computer language for the students in the computer classes. (Right now we
> use QuickBASIC, which is rather out-dated.) I am new to Python myself.
Since
> I'm exploring different ways of teaching Python to someone who has zero
> programming experience, I have been looking through some of the online
> resources. I am currently following a tutorial that was linked on the
> python.org site. If any of you happen to know of excellent resources for
> teaching Python to students with zero programming experience, please let
me
> know.
>

  Alan Gauld's tutorial is great - you can find it at
http://www.crosswinds.net/~agauld

> Now to my question. :) So I'm going through this tutorial and it says to
do
> the following:
>
> s = raw_input("Who are you? ")
>
> That should pass what the user inputs to the variable s. However, when I
run
> the program it gets to where I can input data, but then after I hit enter,
> it doesn't do anything. I just goes to the next line. Nothing I try will
> actually end it accepting input. It just keeps accepting input no matter
how
> many times I hit enter. I even tried ctrl-enter, shift-enter, etc. Oh
yeah,
> and I'm using IDLE in a Windows environment. Anyone have any ideas on why
> this isn't working?
>

  Alright, first off, are you at the interactive window?  If so, then it
will just keep accepting input - that's its job.
  If your not in the interactive window then try altering your script to say
something like...

s = raw_input("Who are you? ")
print s

  Then save and run.
  If your going to go onto tkinter (the standard GUI toolkit for python)
then I suggest you grab the Activestate IDE - it is not written IN tk (as
opposed to IDLE) and handles such things alot better.  Also, I have had bad
experiences with threads in IDLE.
  I'm still relatively new myself, so don't just go on what I say :)

  Glen.

> --Dylan
>
>
> _______________________________________________
> Tutor maillist  -  Tutor@python.org
> http://mail.python.org/mailman/listinfo/tutor
>