Assignment 7: Nondeterminism in Python


Due Wednesday, July 10 at 12:00 PM (hard deadline! - no late submissions)

Goals for This Assignment

By the time you have completed this work, you should be able to:

Provided files:

Step-by-Step Instructions

Step 1: Implement a Basic Grammar-Based Test Case Generator in Python

Download arithmetic_tester.py. You will need to implement two functions in this file:

  1. makeTest
  2. makeTestWithNums

It is recommended to write makeTest first, and to make sure it's working first before moving on to makeTestWithNums. To this end, there is a test suite provided for both procedures (that is, a test suite for the test suite generator), with testMakeTest and testMakeTestWithNums, respectively. The comments in arithmetic_tester.py provide further details.

You can implement these procedures however you wish, as long as it doesn't change how they are called. You can introduce as many helper procedures as you like.

Step 2: Turn in Your Solution Using Canvas

Log into Canvas, and go to the COMP 410 class. Click “Assignments” on the left pane, then click “Assignment 7”. From here, you need to upload the following file:

In addition, if you collaborated with anyone else, be sure to download collaborators.txt and write the names of the people you collaborated with in the file, one per line. Please submit this file along with the other file.

You can turn in the assignment multiple times, but only the last version you submitted will be graded.