how to slice list elements in python code example
Example: python slice second element of list of lists
import numpy as np
A = np.array([[1,2,3,4,5],[1,2,3,4,5],[1,2,3,4,5]])
A[:,:3]
Out[3]:
array([[1, 2, 3],
[1, 2, 3],
[1, 2, 3]])