 
Summary: Program 1 Page 1
CS 2420 Fall 2010
Program 1 20 points
Due September 10, 2010
Recursion
Objective:
Sudoku is a simple solitaire game played on a 99 grid partially filled in with integers in the range 1 to
9. The goal of the game is simply to fill in the empty spaces in the grid with integers in the same range
so that every row, every column, and each of the nine 33 boxes contain the digits 1 through 9.
You can try playing Sudoku yourself where it appears in The Statesman. Or you can play online and
learn more about Sudoku at various sites, including http://www.websudoku.com/ .
The objective of this assignment is to write a recursive function that determines the solution to a Sudoku
input puzzle (if the solution exists), or indicate that no solution exists (if there is no solution possible).
Approach:
You are to write a program that reads 81 integer values from standard input. Blank spaces in the grid
are represented with the numeral 0. After determining the solution, your program is to print the result.
For example, the input stream (for prog1.txt) contains:
0 6 0 1 0 4 0 5 0
0 0 8 3 0 5 6 0 0
2 0 0 0 0 0 0 0 1
