Pallab, please reply to the Tutor list. ---------- Forwarded message ---------- From: "Pallab Amway" <pallabam...@gmail.com> Date: Aug 12, 2016 1:05 AM Subject: Re: [Tutor] need help To: "boB Stepp" <robertvst...@gmail.com> Cc:
> Respected sir,lots of thanks for your advice,but while i am compiling > those programe with python 2.7 no output is coming only showing the > masage "expected indented block"can you sugest any ebook?and please > sent me a expample with if & loop statement which i can compile on my > python 2.7 .yours faithfuly pallab kumar seal > > On 8/12/16, boB Stepp <robertvst...@gmail.com> wrote: > > On Aug 11, 2016 12:15 PM, "Pallab Amway" <pallabam...@gmail.com> wrote: > >> > >> Respected sir > >> > >> Myself pallab kumar seal from India I am using > > python2.7 > >> in my window 7 but while I am using python to compile my program I am > >> getting following error > >> > >> Programe1 > >> > >> age = 21 > >> > >> if age < 12: > >> > >> print( "You ' re still a child!" ) > >> > >> elif age < 18: > >> > >> print( "You are a teenager!" ) > >> > >> elif age < 30: > >> > >> print( "You ' re pretty young!" ) > >> > >> elif age < 50: > >> > >> print( "Wisening up, are we?" ) > >> > >> else: > >> > >> print( "Aren ' t the years weighing heavy?" ) > >> > >> answer > >> > >> > >> expected an indented block > >> > > > > Do you understand how Python uses consistent indentation to delineate > > blocks of code? If not, then you need to research this. > > > > Also, you say you're using Python 2.7. Python 2.x uses print *statements* > > => no parentheses, while Python 3.x uses print *functions*. Something else > > to read up on. > > > > Hope this gives you enough hints to work through your current problems! > > > > And I hope sending from my phone results in a plain text format! > > > > boB > > > > P.S.:. Do you have a good book or online tutorial to use? If not, there > > are plenty of such resources online. > > _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: https://mail.python.org/mailman/listinfo/tutor