I need to extract data from multiple positions in an array.
A simple array would be:-
listing = (4, 22, 24, 34, 46, 56)
I am familiar with slicing. For instance:-
listing[0:3]
would give me:-
(4, 22, 24)
However I am unable to get out multiple slices. For instance:-
listing[0:3, 4:5]
gives me
TypeError: tuple indices must be integers not tuples
Despite Searching two Python books and the Internet I cannot work out the syntax to use.