title: taking n*n matrix input by user in python
body: <p>I am starting to code in python. When I was to take two inputs from user with a space between the two inputs my code was like</p>
  
  <pre><code> min, p = input().split(" ")  
  min=int(min)
  p=float(p)
  </code></pre>
  
  <p>which worked fine. In another such problem I am to take a n*n matrix as user input which I declared as <code>arr=[[0 for i in range(n)] for j in range(n)]</code> 
  printing the arr gives a fine matrix(in a single row though) but I am to replace each element '0'with a user input so I use nested loops as</p>
  
  <pre><code>for i in range(0,n)
      for j in range(0,n)
         arr[i][j]=input()
  </code></pre>
  
  <p>this also worked fine but with a press of 'enter' button after each element. In this particular problem the user will input elements in one row at space instead of pressing 'enter' button. I wanted to know how to use split in this case like in first case above, keeping in mind the matrix is n*n where we don't know what is n. I prefer to avoid using numpy being a beginner with python. </p>