Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Sudoku is a logic game played on a 9x9 grid using the digits 1 through 9. The grid is further subdivided into nine 3x3 boxes.

image text in transcribed

Sudoku is a logic game played on a 9x9 grid using the digits 1 through 9. The grid is further subdivided into nine 3x3 boxes. The goal is to fill in the grid with digits such that one and only one of each digit 1 through 9 appear in every row, column, and box. Create a program that determines whether or not a Sudoku grid filled with numbers is a Sudoku. Import program1.zip (distributed in class) into Eclipse. As discussed in class, make sure that the program is well documented and submitted on time. The code is incomplete, you will have to write the fillGrid and evaluate methods where indicated by the statement: JOptionPane.showMessageDialog(this, "Write the necessary code to ..."); The program starts with an empty grid (See Figure 1). Enter numbers into the grid so that every row, column and 3x3 box contains every digit from 1 to 9 inclusive (see Figure 2) To enter the numbers, click the button, at the bottom of the window, with the number you wish to enter, and then click the button in the grid into which the number should be placed Instead of entering the numbers, there is also an option in the File menu (Fill Grid) that can fill in the numbers read from a file. You will have to complete this code Sudoku1.txt, Sudoku2.txt, and Sudoku3.txt contain data that can be used to test your program The files are located in http://venus.cs.gc.cuny.edu/aabreu/cs212/project1/ After entering the numbers, click the pen (icon next to the 9) to evaluate the grid. You will also have to write the code for the evaluate method and display a message indicating whether or not the grid represents a Sudoku Sudoku v0.99 Sudoku va.99 File Help File Help 6 3 5 289 7 1 7 8 9 61 Figure 1 Figure 2 Sudoku is a logic game played on a 9x9 grid using the digits 1 through 9. The grid is further subdivided into nine 3x3 boxes. The goal is to fill in the grid with digits such that one and only one of each digit 1 through 9 appear in every row, column, and box. Create a program that determines whether or not a Sudoku grid filled with numbers is a Sudoku. Import program1.zip (distributed in class) into Eclipse. As discussed in class, make sure that the program is well documented and submitted on time. The code is incomplete, you will have to write the fillGrid and evaluate methods where indicated by the statement: JOptionPane.showMessageDialog(this, "Write the necessary code to ..."); The program starts with an empty grid (See Figure 1). Enter numbers into the grid so that every row, column and 3x3 box contains every digit from 1 to 9 inclusive (see Figure 2) To enter the numbers, click the button, at the bottom of the window, with the number you wish to enter, and then click the button in the grid into which the number should be placed Instead of entering the numbers, there is also an option in the File menu (Fill Grid) that can fill in the numbers read from a file. You will have to complete this code Sudoku1.txt, Sudoku2.txt, and Sudoku3.txt contain data that can be used to test your program The files are located in http://venus.cs.gc.cuny.edu/aabreu/cs212/project1/ After entering the numbers, click the pen (icon next to the 9) to evaluate the grid. You will also have to write the code for the evaluate method and display a message indicating whether or not the grid represents a Sudoku Sudoku v0.99 Sudoku va.99 File Help File Help 6 3 5 289 7 1 7 8 9 61 Figure 1 Figure 2

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Online Market Research Cost Effective Searching Of The Internet And Online Databases

Authors: John F. Lescher

1st Edition

0201489295, 978-0201489293

More Books

Students also viewed these Databases questions

Question

Explain how cultural differences affect business communication.

Answered: 1 week ago

Question

List and explain the goals of business communication.

Answered: 1 week ago