title: Basic Sudoku checker
body: <p>I am creating a basic sudoku checker with the help of Python.
  However, the result is always displayed as 'False'.
  The code is as follows:</p>
  
  <pre><code>list = [[1,2,3,4],
          [2,4,1,3],
          [3,1,4,2],
          [4,3,2,1]]
  
  def sudoku_check(list):
      n = len(list)
      digit = 1
      while digit &lt;= n:
          row_count = 0
          col_count = 0
          v = 0
          while v &lt; n:
              x = 0
              while x &lt; n:
                  print ("Check")
                  if digit == list[v][x]:
                      row_count = row_count + 1
                  if digit == list[x][v]:
                      col_count = col_count + 1
                  x = x + 1
              v = v + 1
          if col_count != 1 or row_count != 1:
              return False
          digit = digit + 1
      return True
  
  print (sudoku_check(list))
  </code></pre>
  
  <p>I am new to programming. Would appreciate your help on this.
  Thanks</p>