summaryrefslogtreecommitdiffhomepage
path: root/python.html.markdown
diff options
context:
space:
mode:
Diffstat (limited to 'python.html.markdown')
-rw-r--r--python.html.markdown4
1 files changed, 4 insertions, 0 deletions
diff --git a/python.html.markdown b/python.html.markdown
index 08e68407..22d236ac 100644
--- a/python.html.markdown
+++ b/python.html.markdown
@@ -2,6 +2,7 @@
language: python
contributors:
- ["Louie Dinh", "http://ldinh.ca"]
+ - ["Amin Bandali", "http://aminbandali.com"]
filename: learnpython.py
---
@@ -159,6 +160,8 @@ li[1:3] #=> [2, 4]
li[2:] #=> [4, 3]
# Omit the end
li[:3] #=> [1, 2, 4]
+# Revert the list
+li[::-1] #=> [3, 4, 2, 1]
# Remove arbitrary elements from a list with "del"
del li[2] # li is now [1, 2, 3]
@@ -481,6 +484,7 @@ dir(math)
* [The Official Docs](http://docs.python.org/2.6/)
* [Hitchhiker's Guide to Python](http://docs.python-guide.org/en/latest/)
* [Python Module of the Week](http://pymotw.com/2/)
+* [A Crash Course in Python for Scientists](http://nbviewer.ipython.org/5920182)
### Dead Tree