any one know how to retrieve section from this array:
a=[[1, 3, 2, 5, 7, 9, 4, 6, 8],
[4, 9, 8, 2, 6, 1, 3, 7, 5],
[7, 5, 6, 3, 8, 4, 2, 1, 9],
[6, 4, 3, 1, 5, 8, 7, 9, 2],
[5, 2, 1, 7, 9, 3, 8, 4, 6],
[9, 8, 7, 4, 2, 6, 5, 3, 1],
[2, 1, 4, 9, 3, 5, 6, 8, 7],
[3, 6, 5, 8, 1, 7, 9, 2, 4],
[8, 7, 9, 6, 4, 2, 1, 5, 3]]
I mean that i would like to retrieve section 3X3 ,for example,the top left one is:
[[1,3,2],
[4,9,8],
[7,5,6]]
the sections needed to be retrieved are :
left section
[[0:3,0:3]],[[3:6,0:3]],[[6:9,0:3]]
middle section
[[0:3,3:6]],[[3:6,3:6]],[[6:9,3:6]]
right section
[[0:3,6:9]],[[3:6,6:9]],[[6:9,6:9]]
How to retrieve all these sections? Is it necessary to use numpy?