If you want a small code snippet for enumerations in Python and the following code is sufficient for your needs, please go ahead and use it! Running the code is as simple as this:
STATE = enum('GET_QUIZ, GET_VERSE, TEACH')
This recipe was edited and adapted after the author was inspired by seeing other, better enum recipes lying around.
1 2 3 4
def enum(names): "Create a simple enumeration having similarities to C." return type('enum', (), dict(map(reversed, enumerate( names.replace(',', ' ').split())), __slots__=()))()