What's wrong with the code below?
arr=numpy.empty((2,2))
arr[0:,0:]=1
print(arr[1:,1:])
arr=([ [1, 2, 3], [ 4, 5, 6], [ 7, 8, 9] ])
print(arr[1:2, 1])
I am getting the following error and not able to slice the array( fifth line). Please help me with this.
TypeError: list indices must be integers, not tuple.