[Tutor] pyhton
alan.gauld@bt.com
alan.gauld@bt.com
Wed, 26 Dec 2001 16:42:59 -0000
------_=_NextPart_001_01C18E2C.60F13410
Content-type: text/plain; charset="iso-8859-1"
> hello my name is ted and i have a few questions about pyhton. i have
never
> worked with programing but i have worked with computers for a while.
Thats my target audience on my web tutor :-)
> do you know any were it gives more "hands on traingin" and more in depth
help.
Visit the Python web site and go to the Intros and Begginers
sections where several tutors exist, including mine.
also i cannot get this program to work maby you can tell me whats wrong?
>>>input("what is your name?") if ted print"hello ted" else: print"who are
you?"
Split it onto several lines:
>>> name = raw_input("Whats your name? ") #use raw_input for characters
Whats your name? ted
>>> if name == "ted": # must have a colon ':' after the test
... print "Hello ted"
... else: print "Who are you?"
...
Hello ted
>>>
You are very close but there's a few concepts missing. Try one of the tutors
and
don't rush it, there's a lot of things to pick up at the beginning, if you
miss them
early on it will just make life harder later on as you have to unlearn bad
habits.
Alan g.
Author of the 'Learning to Program' web site
http://www.freenetpages.co.uk/hp/alan.gauld
<http://www.freenetpages.co.uk/hp/alan.gauld>
------_=_NextPart_001_01C18E2C.60F13410
Content-type: text/html; charset="iso-8859-1"
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META content="MSHTML 5.50.4807.2300" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#fffbf0>
<DIV><FONT face=Arial><FONT size=2><SPAN class=230464116-26122001><FONT
face="Courier New" color=#0000ff>> </FONT></SPAN>hello my name is ted
and i have a few questions about pyhton. i have never <SPAN
class=230464116-26122001><FONT face="Courier New"
color=#0000ff> </FONT></SPAN></FONT></FONT></DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN class=230464116-26122001><FONT
face="Courier New" color=#0000ff>> </FONT> </SPAN>worked with programing
but i have worked with computers for a while. <SPAN
class=230464116-26122001><FONT face="Courier New"
color=#0000ff> </FONT></SPAN></FONT></FONT></DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN
class=230464116-26122001></SPAN></FONT></FONT> </DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN class=230464116-26122001>Thats my
target audience on my web tutor :-)</SPAN></FONT></FONT></DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN
class=230464116-26122001></SPAN></FONT></FONT> </DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN class=230464116-26122001><FONT
face="Courier New" color=#0000ff> > </FONT></SPAN>do you know any
were it gives more "hands on traingin" and more in depth help.<SPAN
class=230464116-26122001><FONT face="Courier New"
color=#0000ff> </FONT></SPAN></FONT></FONT></DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN
class=230464116-26122001></SPAN></FONT></FONT> </DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN class=230464116-26122001><FONT
face="Courier New" color=#0000ff>Visit the Python web site and go to the Intros
and Begginers </FONT></SPAN></FONT></FONT></DIV>
<DIV><FONT face=Arial><FONT size=2><SPAN class=230464116-26122001><FONT
face="Courier New" color=#0000ff>sections where several tutors exist, including
mine.</FONT> </SPAN></FONT></FONT></DIV>
<BLOCKQUOTE dir=ltr
style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #0000ff 2px solid; MARGIN-RIGHT: 0px">
<DIV><FONT face=Arial size=2>also i cannot get this program to work maby you
can tell me whats wrong?</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV>
<DIV><FONT face=Arial size=2>>>>input("what is your name?") if ted
print"hello ted" else: print"who are you?"</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT> </DIV></BLOCKQUOTE>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face=Arial size=2>Split it
onto several lines:</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face="Courier New"
size=2>>>> name = raw_input("Whats your name? ") #use
raw_input for characters</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face="Courier New"
size=2>Whats your name? ted</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face="Courier New"
size=2>>>> if name == "ted": # must have a colon ':' after
the test</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face="Courier New"
size=2>... print "Hello
ted"</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face="Courier New" size=2>...
else: print "Who are you?"</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face="Courier New"
size=2>...</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face="Courier New"
size=2>Hello ted</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face="Courier New"
size=2>>>></FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face=Arial
size=2></FONT></SPAN> </DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face=Arial size=2>You are very
close but there's a few concepts missing. Try one of the tutors and
</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face=Arial size=2>don't rush
it, there's a lot of things to pick up at the beginning, if you miss them
</FONT></SPAN></DIV>
<DIV dir=ltr><SPAN class=230464116-26122001><FONT face=Arial size=2>early on it
will just make life harder later on as you have to unlearn bad
habits.</FONT></SPAN></DIV>
<DIV dir=ltr><FONT face=Arial size=2>
<P><FONT size=2>Alan g.<BR>Author of the 'Learning to Program' web site<BR><A
target=_blank
href="http://www.freenetpages.co.uk/hp/alan.gauld">http://www.freenetpages.co.uk/hp/alan.gauld</A></FONT>
</P></FONT></DIV></BODY></HTML>
------_=_NextPart_001_01C18E2C.60F13410--