On Tue, Jul 31, 2012 at 5:52 AM, ttmticdi . <ttmti...@gmail.com> wrote: >> > print "Mum is in a %s mood" % (mum_mood) >> > print "Dad is in a %s mood" % (dad_mood) >> >> > > > Hi Victoria! > > Since you have only one format character in the strings above there is > no need to surround the variables mum_mood and dad_mood with > parenthesis. > You only do that when you have multiple formats in your string that > print multiple variables. > > Ex: > No! > print "Hi %s! You like %s and %s" (user_name, x, y) > Yes! print "Hi %s! You like %s and %s" % (user_name, x, y) > > >> >> _______________________________________________ >> Tutor maillist - Tutor@python.org >> To unsubscribe or change subscription options: >> http://mail.python.org/mailman/listinfo/tutor > _______________________________________________ > Tutor maillist - Tutor@python.org > To unsubscribe or change subscription options: > http://mail.python.org/mailman/listinfo/tutor
-- Joel Goldstick _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor