Sudoku is a logic puzzle whose history traces to French puzzles from the 19th century. The modern form of Sudoku became widely popular in the early 21st century when newspapers started to publish daily puzzles.

Sudoku puzzles can be readily solved by a computer using techniques covered in introductory programming courses. Consequently, Sudoku offers a chance to practice these techniques while developing an application that someone can use when stuck trying to solve a Sudoku puzzle!

Expected duration
4–6 hours
Deadline
2359 on Lesson 19
Points
65 points
Submission
Canvas

Learning Objectives

Implement software by following a specification

  • Analyze requirements for a software system
  • Develop code that adheres to a specified design
    • Use a design pattern to improve the flexibility of software
  • Use test-driven development (TDD) to emphasize simple design and software quality

Help Policy

Authorized Resources
Any, except others’ code
Notes
Never copy another person’s work and submit it as your own

Do not jointly work on this assignment, but you may ask classmates syntax questions

You must document all help received from all sources, including the instructor and instructor-provided material (including the textbook), except for the following:

  • Resources related to syntax unless the resource is a classmate (i.e., document any interactions you have with classmates)

Instructions

Use the provided link (distributed separately) to access the assignment in GitHub Classroom.

Implement the specification for representing a Sudoku puzzle and using backtracking recursion to solve a Sudoku puzzle. Template code is provided to ease the implementation of classes in Python.

Test code is provided to facilitate automated testing. Do not modify the test code! A correct implementation of the specification should pass all the automated tests.

Submission

Create an archive of your Git repository (you can use GitHub’s “Clone or download” button when viewing your repository for this purpose) and submit that archive to Canvas. Be sure to include your documentation statement as part of the submission.

GitHub Classroom also tags the latest commit at the due date for the assignment.

Grading

The following grading rubric will be used for this assignment:

Description Points
Unit Tests (13 @ 3 points each) 39
Integration Tests (4 @ 5 points each) 20
PEP 8 compliance 6

No partial credit will be awarded for individual tests, including PEP 8 compliance, unless you can prove that a test case is invalid (e.g., violates the specification).

Automated Tests

GitHub Actions tests your code when you push your changes to GitHub (i.e., continuous integration (CI)). The entire class shares the resources provided for auto-grading; more specifically, there is a maximum number of minutes per month for GitHub Actions, and each job counts toward that maximum. You should test locally before pushing to GitHub.

Because GitHub Actions resources are shared, each workflow run in excess of 25 will incur a 1-point penalty.

To encourage judicious use of shared resources, the aforementioned penalty will be applied to deter running an excessive number of jobs that don’t pass the tests. If you test locally, then you should have no trouble avoiding a penalty. You may check the number of workflow runs by clicking on the “Actions” tab of your repository.