import numpy as np
a = np.array([[1,2],[1,2]])
a
(e.g.a is a 2 by 2 array)?size()
returns 4 and that doesn't help very much.
import numpy as np
>>> np.shape(a)
(2,2)
>>> a = [[1,2],[1,2]]
>>> np.shape(a)
(2,2)
>>> a = ((1,2),(1,2))
>>> np.shape(a)
(2,2)