The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | May 2017 |
| Last Sign in: | 406 Weeks Ago, 1 Day Ago |
| Questions Answered: | 66690 |
| Tutorials Posted: | 66688 |
MCS,PHD
Argosy University/ Phoniex University/
Nov-2005 - Oct-2011
Professor
Phoniex University
Oct-2001 - Nov-2016
George has started doing the Sodoku puzzles in the local newspaper while he waits for class to start. He loves them so much that he has decided that it would be fun to create a program that solved them for him. Help George out by writing a program that will input a sodoku board, then a list of positions and numbers to go in that specific position, and output whether or not those numbers could go in those spots without violating any rules. In Sodoku, the numbers 1-9 cannot be repeated in any column, row, or square..
Â
Â
Â
9 rows of 9 numbers from 0-9 followed by an (x, y) coordinate and a number to go there. A 0 will refer to no number being in that spot
Â
Â
YES/NO depending on whether or not the number can go there.
Â
Tips:
Â
Â
Â
Â
Â
Â
Input: 0 0 4 7 0 2 0 8 0 0 2 0 0 1 0 0 0 0 7 8 0 4 0 0 9 0 0 6 9 3 0 0 8 0 0 0 2 0 0 0 0 0 0 0 8 0 0 0 6 0 0 3 9 7 0 0 2 0 0 7 0 3 4 0 0 0 0 3 0 0 2 0 0 7 0 2 0 1 8 0 0 4 4 1 4 4 2 4 4 3 4 4 4 4 4 5 4 4 6 4 4 7 4 4 8 4 4 9 -1 Output: NO NO NO YES YES NO YES NO YES
Hel-----------lo -----------Sir-----------/Ma-----------dam-----------Tha-----------nk -----------You----------- fo-----------r u-----------sin-----------g o-----------ur -----------web-----------sit-----------e a-----------nd -----------and----------- ac-----------qui-----------sit-----------ion----------- of----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n.P-----------lea-----------se -----------pin-----------g m-----------e o-----------n c-----------hat----------- I -----------am -----------onl-----------ine----------- or----------- in-----------box----------- me----------- a -----------mes-----------sag-----------e I----------- wi-----------ll