We have written a program that serves up one of twenty-four questions. The questions are written directly in the source code file. But what if we want to store an unlimited number of questions? What if we would like to let people add questions without having access to our source code? Maybe we even want to let players submit questions. We need to store our questions in an external file of some kind. We could store them in a simple text file and draw them out as needed, but there are some major problems with this approach:
|