def _quiz_endless(wordlist):
    'Runs quizzes in batches of 20 until quit or exit is answered.'
    (correct, answered) = (0, 0)
    finished = False
    while (not finished):
        results = _quiz(wordlist, 20)
        correct += results[0]
        answered += results[1]
        finished = (not results[2])
    return (correct, answered)
Runs quizzes in batches of 20 until quit or exit is answered.
def _quiz_endless(wordlist):
    
    (correct, answered) = (0, 0)
    finished = False
    while (not finished):
        results = _quiz(wordlist, 20)
        correct += results[0]
        answered += results[1]
        finished = (not results[2])
    return (correct, answered)