[Tutor] raw_input function
Alan Gauld
alan.gauld at blueyonder.co.uk
Wed Jan 28 18:00:21 EST 2004
> > Where can I go to get some general information on how
> > the raw_input function works?
>
> I think you have to look in the source code (C).
Aha! I hadn't thought of that interpretation. You want to understamd
how the function is actually written? As Karl says you can read
the C source code or conceptually think of it as being a little
like this:
def raw_input(prompt):
print prompt,
return sys.stdin.readline()
Its actually a wee bit cleverer than that I think, but so far as
we the users go its pretty close.
Does that help?
Alan G.
More information about the Tutor
mailing list