Writing a random-generating quiz, need to recall the object that was randomly generated
<p>I'm very new to python, so I'm sure my code is prodigiously inefficient, etc, but I'm just feeling my way around and learning by doing at the moment, so excuse my general ignorance.</p>

<p>My quiz currently takes a series of quotes and randomly prints the first 20 characters of them (via slice), the idea being that the quizee recites the rest. </p>

<p>I would like to add the ability to fetch the entire quote, but I don't know how to tell python to recall the last object the random module generated.</p>

<p>Here is my code:</p>

<pre><code>import random
control = True

JCIIiii34 = "Valiant men never taste of death but once"
SonnetSeventeen = "If I could write the beauty of your eyes,\nAnd in fresh numbers number all your graces,\nThe age to come would say this poet lies,\nSuch heavenly touches ne'er touched earthly faces."
SonnetEighteen = "So long as men can breath and eyes can see,\nSo long lives this, and this gives life to thee."
JCIii101 = "I had as lief not be as live to be\nIn awe of such a thing as I myself"


print "After quote type 'exit' to leave, or 'next' for next quote"

while control:
    quote = random.choice([SonnetSeventeen,SonnetEighteen,JCIIiii,JCIii])
    print quote[:20]
    var = raw_input ("\n")
    if var == "exit":
        control = False
    elif var == "next":
        print "\n"
        control = True
</code></pre>

<p>So what I'd like to be able to do is add one more elif statement saying</p>

<pre><code>elif var == "answer":
     print #the full quote
</code></pre>

<p>Where the print statement calls to the object that was originally sliced, but prints it in full.</p>

<p>I have read the python library entry for the random module and found no answer. </p>

<p>I'm also open to more efficient ways of doing this (I know I can store the quotes in a separate file, but haven't figured that out yet).</p>

<p>Thanks in advance for any help!</p>
