Python Madlibs.py code and error message

Stephen Hansen me+python at ixokai.io
Thu Apr 28 00:55:59 EDT 2016


On Wed, Apr 27, 2016, at 09:37 PM, Cai Gengyang wrote:
> print STORY % (Adjective1, name, Verb1, Adjective2, Noun1, Noun2, animal,
> food, Verb2, Noun3, fruit, Adjective3, name, Verb3, number, name ,
> superhero_name, superhero_name, name, country, name, dessert, name, year,
> Noun4)

Python is case-sensitive. "Adjective1" and "adjective1" are separate
things. In your code you're reading into "adjective1".

-- 
Stephen Hansen
  m e @ i x o k a i . i o



More information about the Python-list mailing list