Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- computeValues(array, row, column)
- FOR count = 1 - 9
- IF !containsNumber(array, count, row, column)
- PRINT count
- containsNumber(array, number, row, column)
- FOR count 0-8
- IF array[row][count] is number
- RETURN true
- FOR count 0-8
- IF array[count][column] is number
- RETURN true
- FOR count 0-2
- IF array[row / 3][column / 3 + count] is number
- RETURN true
- FOR count 0-2
- IF array[row / 3 + 1][column / 3 + count] is number
- RETURN true
- FOR count 0-2
- IF array[row / 3 + 2][column / 3 + count] is number
- RETURN true
- RETURN false
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement