author | Nishanth <nishanth@fossee.in> |
Tue, 12 Oct 2010 10:47:28 +0530 | |
changeset 330 | efb8ddf26aff |
parent 233 | ab748264f726 |
child 333 | 91b427241f8f |
permissions | -rw-r--r-- |
233
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
1 |
Creating a tuple:\\ |
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
2 |
{\ex \lstinline| t = (1, "hello", 2.5)|} |
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
3 |
|
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
4 |
Accessing elements of tuples:\\ |
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
5 |
{\ex \lstinline| t[index] Ex: t[2]|} |
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
6 |
|
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
7 |
Accessing slices of tuples:\\ |
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
8 |
{\ex \lstinline| t[start:stop:step]|} |
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
9 |
|
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
10 |
Swapping values:\\ |
ab748264f726
Made sets.rst into the new template form
Nishanth <nishanth@fossee.in>
parents:
diff
changeset
|
11 |
{\ex \lstinline| a, b = b, a|} |