diff options
| author | jmaud <maudlin.johnathan@gmail.com> | 2014-10-15 11:34:50 -0400 | 
|---|---|---|
| committer | jmaud <maudlin.johnathan@gmail.com> | 2014-10-15 11:34:50 -0400 | 
| commit | fe277959606857f2690b4d6dd224fffc6a550d34 (patch) | |
| tree | 1f4fe866661f06bae6f5fcc702b9450da32e9627 /python.html.markdown | |
| parent | 54835f209475cf6ace7fcd7fab8140ecedcec340 (diff) | |
| parent | bc6a21835f862a4c8b386fce48aebd2cdd1a5232 (diff) | |
Merge branch 'master' of github.com:adambard/learnxinyminutes-docs
Merge changes
Diffstat (limited to 'python.html.markdown')
| -rw-r--r-- | python.html.markdown | 22 | 
1 files changed, 13 insertions, 9 deletions
| diff --git a/python.html.markdown b/python.html.markdown index 390c7b76..ba236fb3 100644 --- a/python.html.markdown +++ b/python.html.markdown @@ -3,6 +3,7 @@ language: python  contributors:      - ["Louie Dinh", "http://ldinh.ca"]      - ["Amin Bandali", "http://aminbandali.com"] +    - ["Andre Polykanine", "https://github.com/Oire"]  filename: learnpython.py  --- @@ -54,19 +55,22 @@ to Python 2.x. Look for another tour of Python 3 soon!  # Modulo operation  7 % 3 # => 1 +# Exponentiation (x to the y'th power) +2**4 # => 16 +  # Enforce precedence with parentheses  (1 + 3) * 2  # => 8  # Boolean Operators -+# Note "and" and "or" are case-sensitive -+True and False #=> False -+False or True #=> True -+ -+# Note using Bool operators with ints -+0 and 2 #=> 0 -+-5 or 0 #=> -5 -+0 == False #=> True  -+2 == True #=> False  +# Note "and" and "or" are case-sensitive +True and False #=> False +False or True #=> True + +# Note using Bool operators with ints +0 and 2 #=> 0 +-5 or 0 #=> -5 +0 == False #=> True +2 == True #=> False  1 == True #=> True  # negate with not | 
