On Wed, Sep 12, 2012 at 5:32 AM, <[email protected]> wrote:
> Hello,
>
> I'm very new thanks in advance for your help.
>
> My If statement is:
>
> If age < (40):
this will work, but python doesn't need the parentheses around the
second argument. You can use it to make the logic more clear, but for
a single term it doesn't
> Print("you are young.")
> Else:
in python else is lower case
> Print("You look great.")
>
> Basically what I want to do is have a sentence using print that includes the
> results of the If or Else which is based on the users input of age.
>
> I don't know if I'm doing something wrong by doing it this way. I can't
> figure it out.
>
so try this:
if age < 40:
print ("you are young")
else:
print ("you look great!")
--
Joel Goldstick
_______________________________________________
Tutor maillist - [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor