Last active
August 29, 2015 14:06
-
-
Save r2k0/40a3c311866f27e4b740 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Serve current directory tree at http://$HOSTNAME:8000/ | |
python -m SimpleHTTPServer | |
#swap | |
b, a = a, b | |
# | |
a = [1,2,3,4,5] | |
a[::2] # iterate over the whole list in 2-increments [1,3,5] | |
a[::-1] # reversed [5,4,3,2,1] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment