manipulating-lists/quickref.tex
author Anoop Jacob Thomas<anoop@fossee.in>
Wed, 10 Nov 2010 19:00:23 +0530
changeset 446 2ce824b5adf4
parent 423 0f0f4993cffe
permissions -rw-r--r--
removed unwanted data from slides.org file for getting started with functions.

Slicing \& Striding a list:\\
{\ex \lstinline|    A[start:stop:step]|} \lstinline|stop| excluded

Sorting a list:\\
{\ex \lstinline|    sorted(A)|} -- returns new list
{\ex \lstinline|    A.sort()|} -- in-place sort

Reversing a list:\\
{\ex \lstinline|    A[::-1]|} -- returns new list
{\ex \lstinline|    A.reverse()|} -- in-place reverse