Coding a Waterloo Computer Museum Game in BASIC

Tuesday, April 16, 2024
by Charlotte Wipp
BASIC code

What is BASIC?

BASIC (Beginners’ All-purpose Symbolic Instruction Code) was created in 1963 at Dartmouth College. The computer language was intended to be a user-friendly language, different from the languages available at the time, made for scientific and mathematical purposes.  

Learning BASIC

While learning about the computers in the museum, I discovered that a lot of them use the language BASIC to operate. BASIC stands for Beginners’ All-purpose Symbolic Instruction Code, as it was designed to be easy to learn and use. It was developed at Dartmouth in 1963 so that computers could be used without writing custom software. The development of microcomputers in the 1970’s pushed others to develop their own versions of BASIC, such as Microsoft BASIC.  

After doing some research I found old textbooks on beginner BASIC, specifically for the Commodore 64 because I liked the look of the computer the most. In addition to this I downloaded the VICE emulator, which gives you access to emulators for all the older Commodore software. This was all I needed to begin reading through the textbook and learning the statements.  

Something to note was that to create multi-line code you need to start each line with a number, which is commonly done by starting at 10 and going up in steps of ten. This method allows you to later return to the code by using the “List" command to correct the line shown or even add in code in between lines (i.e. lines 10-20 can have 15 if you forgot to add something). To represent a number a variable like X is used, in comparison, storing a string like “hello” a variable like X$ is used. Therefore, to ask the user for a word, number, or symbol the command “INPUT” is followed by the appropriate variable type (i.e. X for a number or X$ for a word or symbol). Finally, typing run and hitting return will start your program. BASIC is a relatively simple language so the more you practice the more hidden tricks or shortcuts you pick up.  

With this knowledge I made a game that includes the things I learned while trying to understand the history of the Museum. My code was relatively simple: ask the question, ask for an input, check if the given answer was correct with an if statement, and reward points if it was.  

Want to play the Waterloo Computer Museum game?


Download the VICE emulator onto your computer, this allows you to emulate many Commodore computers such as the CBM, VIC-20, PET, and the C-64 which I used.  

Take this  and download it onto your computer as well. Load up the program "x64sc" located in the VICE folder, within the directory labeled bin. 

Once you have the C-64 emulator up and running here are the steps to follow (type the exact code listed below in between the *, i.e. *run* will appear as RUN):

  1.  Download the file attached here called uwquiz (Under "External Links") or here.
  2. Go to File, then Smart Attach, select uwquiz, then Attach/Load (located in the bottom right corner)
  3. It will bring you back to the C-64 screen, type into the program *load "uwquiz",8* 
  4. Type on the screen *run* and begin the quiz!


Click this link and play the game in your browser.

Some of the quiz questions and answers!

What language, developed at Waterloo, won third place in the global chess championship?


The program was written in the mid 1970s by a team of undergraduate students at Waterloo. It was written in Fortran, and was was the predecessor of another program called Treefrog. Ribbit won second place at the World Computer Chess Championship in 1974 (WCCC) and won the North American Computer Chess Championship in 1974.

What text did Waterloo work to computerize in 1989?

The Oxford English dictionary. 

Read more here to learn more about the Oxford English Dictionary project at Waterloo!

Waterloo's IBM 360/75 was once the largest and fastest computer in Canada. How much did it cost?

Waterloo purchased the IBM 360/75 for two million dollars. 

In 1968 it was decided that the newly built Mathematics and Computing building would include a IBM 360/75 at its center. Luckily for Waterloo, the Ontario government was funding most of the building's construction and furniture. The first permanent computer at Waterloo was bought under the title of furniture, the computer which was the same model that NASA used to send astronauts to the moon. 

Read more about this caper here.

What does PC stand for?

PC is an abbreviation of Personal Computer. 

What was the colour of the notorious waterloo computer room?


The Red Room was located in the Math and Computing building, and held all of Waterloo's main computers. 

See photos and stories here!

About the Author

Charlotte is a Physics and Astronomy student currently in her 2B term at Waterloo. She enjoys tinkering and creating all forms of art in her free time. She works at the Computer Museum as their current Winter 2024 coop student.