[Tutor] List help

george wu georgextwu at yahoo.com
Sat Nov 20 20:06:38 CET 2010


x=0
y=0
w=raw_input("Input: ")
w=list(w)
for x in range(len(w)):
  a=w[x]
  t=0
  print a
  if a==2 or a==4 or a==6 or a==8 or a==10:
    t=a/2
    print "hi"

When I run this program, it doesn't print "hi". Can you please tell me why?



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20101120/ce7217d9/attachment-0001.html>


More information about the Tutor mailing list