Prisoners invented games to stay sane
Speer imagined a walking trip to Jerusalem, a pilot played eighteen holes in his head every day, and Hungarian prisoners ran a contest to translate a poem, with soap on a shoe as their writing surface. Each of them set goals, watched for feedback and made the task harder over time.
From Csikszentmihalyi, 1990, ch. 4. Csikszentmihalyi, M. (1990). Flow: the psychology of optimal experience. New York: Harper & Row. (Edition of the copy read not established: the text file has no title or copyright page. Open Library gives 1990, Harper & Row, as the first edition; the Harper Perennial paperback of 1991 is ISBN 978-0-06-092043-2. No DOI.)