Looks like you are new to python.
1.Indentation is must in Python. - Your code is not indented properly.
2.Python is NOT C/C++ you just can't neglect all the white spaces. (unless you choose to read all input at once)
So, reading 'n' numbers from a line and 'n' numbers from 'n' lines are two "different" things here.
Now, depending on how many numbers you want to read from a line, you can directly convert that to an int, or you can split it and then convert them to ints.