isSolved :: Sudoku -> Bool
isSolved sudoku
  | product sudoku == 0 = False
  | map (length . nub) sudokuRows /= map length sudokuRows = False
  | map (length . nub) sudokuColumns /= map length sudokuColumns = False
  | map (length . nub) sudokuBoxes /= map length sudokuBoxes = False
  | otherwise = True
  where sudokuRows = chunksOf 9 sudoku
        sudokuColumns = transpose sudokuRows
        sudokuBoxes = map concat $ concatMap transpose $ chunksOf 3 $ map (chunksOf 3) $ chunksOf 9 sudoku
isSolved :: Sudoku -> Bool
isSolved sudoku
  | product sudoku == 0 = False
  | map (length . nub) sudokuRows /= map length sudokuRows = False
  | map (length . nub) sudokuColumns /= map length sudokuColumns = False
  | map (length . nub) sudokuBoxes /= map length sudokuBoxes = False
  | otherwise = True
  where sudokuRows = chunksOf 9 sudoku
        sudokuColumns = transpose sudokuRows
        sudokuBoxes = map concat $ concatMap transpose $ chunksOf 3 $ map (chunksOf 3) $ chunksOf 9 sudoku
isSolved sudoku
  | product sudoku == 0 = False
  | map (length . nub) sudokuRows /= map length sudokuRows = False
  | map (length . nub) sudokuColumns /= map length sudokuColumns = False
  | map (length . nub) sudokuBoxes /= map length sudokuBoxes = False
  | otherwise = True
  where sudokuRows = chunksOf 9 sudoku
        sudokuColumns = transpose sudokuRows
        sudokuBoxes = map concat $ concatMap transpose $ chunksOf 3 $ map (chunksOf 3) $ chunksOf 9 sudoku