fl <rxjw...@gmail.com> writes: > In Python, ':' is used to indicate range (while in Matlab I know it can be > used > to control steps). How to index an array with 0, 5, 10, 15...995?
Just use slicing: >>> L = range(1000) # your array goes here >>> L[::5] [0, 5, 10, 15, ..., 995] # Python 2 range(0, 1000, 5) # Python 3 -- Akira -- https://mail.python.org/mailman/listinfo/python-list