Evan
b4ca1f76e2
Python decorators example added ( #2408 )
2017-02-09 16:57:30 +01:00
Adam Bard
79004c5b4a
Merge pull request #2571 from Smosker/patch-1
...
[python/en] Fix a bug
2017-02-01 13:56:43 -08:00
David Haberthür
4737819e5d
Made the file pep8
compliant ( #2601 )
...
Actually nearly compliant, I ran `pep8 code.py --ignore=E402,E501,E712`
2016-12-20 15:04:12 +01:00
Christopher Lorton
e25918acab
Fix comment in set comprehension example ( #2580 )
...
The result should be {'a', 'b', 'c'} (not {'d', 'e', 'f'}).
2016-11-21 10:38:39 +01:00
Smosker
ac6d64168f
Fix a bug
...
Should add return to double_numbers function, without it next expression wiil fall with "TypeError: 'NoneType' object is not iterable" error
for value in double_numbers(range(1000000)): # `test_non_generator`
print value
if value > 5:
break
2016-11-15 16:10:56 +04:00
J. Ryan Rembert
e053806775
[python/en] Set, dict, and generator comprehensions ( #2298 )
...
* Add set and dict comprehensions for python 2 and 3
* Clean up formatting and generator explanation
* Include documentation for generator comprehensions
2016-07-03 10:47:57 +02:00
Prashant Khanduri
0387bd30fc
Generator explanation for python ( #1870 )
...
More details and code on the same example as before.
2016-06-26 14:50:05 +02:00
Devin Soni
912d546dc7
add dict.items() ( #2290 )
2016-06-26 14:30:39 +02:00
ven
b3b5ece63c
String length by @thesourabh
2016-06-16 15:18:30 +02:00
Divay Prakash
5f89f277b9
fixed whitespaces & content extending beyond 80 chars
2016-03-18 12:23:18 +05:30
ven
2c94436824
Merge pull request #1288 from DaKnOb/fixpymod
...
[python/en] Add note about Python Module Order of Import
2016-03-10 23:00:50 +01:00
sarthfrey
39c83718b1
removed merge stuff
2016-01-25 18:34:25 -05:00
sarthfrey
279c28ce7d
Merge remote-tracking branch 'adambard/master'
...
# Conflicts:
# python.html.markdown
2016-01-25 18:26:23 -05:00
Geoff Liu
24e520a3cc
Merge pull request #1790 from jxu093/master
...
Added Python Resource
2015-12-18 17:30:53 -05:00
sarthfrey
299d064ecf
Added Python Resources
2015-12-16 16:41:07 -05:00
Aayush Ranaut
dc675a47ed
Merged and removed confusing comments in python
2015-12-05 11:10:16 +05:30
EL
a4a7b2dd83
fixed unintended opposite meaning
2015-11-02 16:30:15 +03:00
Aayush Ranaut
0049a475ed
Removed confusing comments
2015-10-31 22:20:51 +05:30
Spurlow
0e2b669c17
Merge pull request #1847 from cnu/master
...
Add one more string formatting example
2015-10-31 19:24:19 +08:00
Adam Bard
15c9543ebc
Merge pull request #1898 from yihongang/python_truthiness
...
add more details on truthiness
2015-10-31 19:02:26 +08:00
Adam Bard
4f1b8654a0
Merge pull request #1927 from TheRakken/patch-1
...
[python] Minor correction
2015-10-31 18:19:38 +08:00
Elijah Karari
ab1acb1bb2
Updated tuple examples for clarity
2015-10-31 09:56:06 +03:00
Elijah Karari
5bda926dcc
Minor correction
...
calling li.index(2) with li as [1, 2, 3, 4, 5, 6] will return 1 not 3
2015-10-31 09:47:55 +03:00
yihong
14c85ba0ff
add more details on truthiness
2015-10-30 05:04:41 +08:00
Geoff Liu
ba4cbab87a
Merge pull request #1676 from vipulroxx/patch-1
...
Modified string format [python/en]
2015-10-29 23:26:59 +08:00
Vipul Sharma
cdd64ecee3
80 char and proper commenting
2015-10-29 15:23:37 +05:30
Srinivasan R
db903ac5b6
Add one more string formatting example
2015-10-28 16:25:54 +05:30
jxu093
e60a7d73e8
Added Python Resource
2015-10-25 22:19:40 -04:00
payet-s
b238a58c97
[python/en] Fix typos
2015-10-22 12:49:49 +02:00
Vipul Sharma
a6eb459b61
Modified string format [python/en]
2015-10-20 09:57:53 +05:30
MDS
c60ddc6ef5
Updated official python docs to always use the latest version of python 2
2015-10-20 01:01:14 +13:00
Levi Bostian
3d70c872e4
Merge pull request #1560 from ankitaggarwal011/python27-ternary-operator-doc-add
...
[python/en] Adding documentation on ternary operator
2015-10-18 12:15:55 -05:00
Levi Bostian
a3db78c73d
Merge pull request #1489 from evuez/patch-2
...
[python/en] Add some stuff to lists, tuples, dicts, sets and classes
2015-10-18 12:07:53 -05:00
Ankit Aggarwal
451ccaec5b
Adding documentation on ternary operator
2015-10-16 20:42:03 +05:30
evuez
85adff2c39
Merge 'master' of github.com:adambard/learnxinyminutes-docs
2015-10-16 10:42:41 +02:00
viv1
a9bcaffd36
[python/en]...Added some info on division
2015-10-16 12:57:31 +05:30
evuez
375f0c18ae
Add some stuff to lists, sets and classes
...
This is meant to match Python 3 update.
Lists: added remove, insert and index
Sets: added ^, <=, >= operators
Classes: added propery decorator (including getter, setter, deleter)
2015-10-14 18:43:23 +02:00
Levi Bostian
a779d9cfb6
Merge pull request #1471 from ankitaggarwal011/python27-input-operations-add
...
[python/en] Added instructions on how to perform input operations
2015-10-14 09:47:42 -05:00
Ankit Aggarwal
e1d2f8c718
Updated the input() method usage and description
2015-10-14 10:27:25 +05:30
Matthias Bussonnier
c05400477b
Update Python 2 vs Python 3
...
Add fact that Python 2 is reaching end of life.
And note that you can use `__future__` to add Python 2 and 3 compatible code.
2015-10-13 17:56:48 -07:00
Ananya W Cleetus
ba06e9af37
Update python.html.markdown
2015-10-12 11:56:37 -04:00
Ankit Aggarwal
9ee3a68720
Added input operations in learn Python 2.7 doc
2015-10-11 19:51:43 +05:30
Cadel Watson
777423dcc5
Add examples of higher-order functions taking multiple arguments
2015-10-07 17:01:28 +11:00
Jesse Huang
f35472d8d2
Removed random "r"
2015-10-02 14:00:54 -04:00
DaKnOb
13807790e4
Add note about Python Module Order of Import
2015-10-02 16:49:51 +03:00
Adam Bard
09874aa5c0
map->dict
2015-09-30 10:48:59 +08:00
Denis Gladkikh
3e93c5e5f4
Update python.html.markdown
2015-09-01 10:23:31 -07:00
Denis Gladkikh
a24e5ef7a1
Python: add finally and with statements
...
https://docs.python.org/2/tutorial/errors.html
2015-09-01 09:27:40 -07:00
Al Sweigart
8a968db2bc
Added links to the free book "Automate the Boring Stuff with Python" to the "Free Online" section.
2015-07-23 11:24:40 -07:00
Mark Miller
d995a0ae27
Changed %s formatting to {n} style.
...
If line 117 is accurate, then {n} style string formatting is the preferred style, and it should be reflected in the examples.
2015-07-16 16:45:25 -05:00
Michael Herman
c6caa7664c
Update python.html.markdown
2015-07-05 21:12:12 -06:00
Michael Herman
92096a65ed
python/en - added two resources
2015-07-05 08:35:31 -06:00
Rinoc Johnson
5ebe2dcb6e
Clarify wording for list reversal.
2015-04-30 19:31:38 -04:00
Rinoc Johnson
e13e00945d
Fix Python typo.
2015-04-30 17:56:01 -04:00
Sriram Sundarraj
c2963cdc31
[python/en] Removed python3 print.
2015-04-24 23:29:01 +05:30
Sriram Sundarraj
6b6342a7dc
[python/en] Moved to default python2 print statements.
2015-04-24 22:57:33 +05:30
Sriram Sundarraj
98aa4ef43c
[python/en] Added range(start, stop).
2015-04-24 01:50:17 +05:30
Sriram Sundarraj
2ad26dd44a
[python/en] Adding strings without + added.
2015-04-23 01:30:40 +05:30
suuuzi
22a0f44e64
Refering Python3 tutorial link
2015-02-04 15:36:20 -02:00
Louie Dinh
28fcbc8e1c
Fix typo
2014-12-23 11:23:22 -08:00
Doug Ilijev
d886036b59
[python/en] Fix 80 col limit and clarify a few points.
2014-11-17 01:26:19 -06:00
Jack Hooper
4d85f161d8
More apostrophe fixes
...
I hate to be that guy, but... I found a couple more.
2014-11-12 02:03:50 +11:00
Jack Hooper
0429c31d6d
Updated note regarding Python 3 tutorial.
2014-11-12 00:30:19 +11:00
Jack Hooper
0698ed27c1
There's no apostrophe in 90s
...
Apostrophes are for indicating an abbreviation or for denoting possession. '90s' is merely a plural. It is an abbreviation of 1990s, so technically it ought to be '90s, but for all intents and purposes this is optional.
2014-11-12 00:28:03 +11:00
Levi Bostian
132823d274
Merge pull request #795 from marvelousNinja/plus_signs_in_python
...
[python/en] Removed unnecessary plus signs in bool operators section
2014-10-09 20:07:57 -05:00
Andre Polykanine A.K.A. Menelion Elensúlë
a2043f3adb
Gosh, what happened to me today?( Fixed the left bracket
2014-10-09 23:22:24 +03:00
Andre Polykanine A.K.A. Menelion Elensúlë
68c9aed134
Corrected as per @iirelu's comment
2014-10-09 23:06:24 +03:00
Andre Polykanine A.K.A. Menelion Elensúlë
39d8753d52
[python/en] Adding exponentiation operator
2014-10-09 22:49:47 +03:00
Alexander Sologub
6629b5cd39
[python/en] Removed unnecessary plus signs in bool operators section
2014-10-09 19:50:55 +03:00
Steven Basart
81b4f49e99
[python/en] Added Bool operators
...
Modified Bool operators
2014-09-07 19:32:46 -04:00
Steven Basart
62f4c0de22
[python/en] Added Bool operators
...
Bool operators
2014-09-07 19:22:01 -04:00
Evgeniy Ginzburg
cb3217fc35
Merge https://github.com/adambard/learnxinyminutes-docs
...
Added two minor changes in integer division to make it clear
2014-08-06 23:45:44 +03:00
Evgeniy Ginzburg
daf83c9123
aded negative integer division same as in python3
2014-08-06 23:43:37 +03:00
Mikael E. Wikner
472142d11f
Squashed commits to prepare for merge
...
moved underscore for range variable, added comment
renamed parameter in beg decorator
added comment about double underscores
Update python.html.markdown
2014-08-06 00:10:52 +02:00
Shashwat986
65a1b6279f
Update python.html.markdown
...
range() is not a generator in python 2.x
2014-08-05 01:06:54 +05:30
Shashwat986
e6a289be49
Update python.html.markdown
...
Added more details to try/except section.
2014-08-02 19:37:28 +05:30
Steven Basart
0dcc5640b6
[python/en] added int div, modulo, and scoping
...
Added integer or truncation division, the modulo operator which were missing from operators section. Added function scoping in the functions section.
2014-07-13 14:52:31 -04:00
Steven Basart
2a9a4f39ba
[python/en] added int div, modulo, and scoping
...
Added integer or truncation division, the modulo operator which were missing from operators section. Added function scoping in the functions section.
2014-07-13 14:51:34 -04:00
Juan David Pastas
fce8598a74
Python: clearer add lists note.
2014-05-01 13:53:01 -05:00
Sam Dodrill
777c333ff0
Remove references to hash and hashtag in favor of number symbol
2014-04-14 11:15:08 -07:00
Guillermo Garza
7db61d1ce1
Modify python to be pep8 compliant
...
This mostly adds spaces.
2014-03-21 18:14:55 -05:00
Mark Whiting
da3b7c3520
Better explanation of list slices
...
Step size and list slice syntax was not quite clear.
Upon seeing li[::-1] as it was previously, I was not sure what this really meant so I looked it up and found that this section of the guide may benefit from more explanation.
2014-02-17 21:07:29 -05:00
charalambosp
3233394cd5
fix section number
2014-02-16 18:37:02 +00:00
charalambosp
550b9c9f2e
generators & decorators
2014-02-16 18:36:09 +00:00
Adam Brenecki
1e60055977
[python] == doesn't coerce types; use bool() to demonstrate truthiness instead. Closes #418 .
2013-11-26 18:12:53 +10:30
Piotr Migdał
f5c9b80377
added an online intro into Python for scientists
2013-11-19 17:17:28 +01:00
Amin Bandali
eb8afb2ff2
reverting a list using slices
2013-11-11 23:17:34 -05:00
Adam Brenecki
de36671ac1
[python] Change to print function, as per #119
2013-09-20 19:49:38 +09:30
Adam Brenecki
6d8ffb19b4
[python] Fix typo in comment, as per #265
2013-09-20 19:33:39 +09:30
Adam Brenecki
1405dc6387
[python] Clarify setdefault, as per #234
2013-09-20 19:32:58 +09:30
Haydar Kulekci
de027ddf9e
regular quotes instead of `.
2013-08-23 09:54:21 +03:00
Haydar Kulekci
8c1a1d8a7b
some python keywords, which are in comments, enclosed in quotation marks to become clear (understandable)
2013-08-23 00:06:47 +03:00
michaelstewart
10ffa5a781
Added an apostrophe to Its
2013-08-08 18:49:45 +10:00
cssmagic
0dff3a936c
Fix tiny typos.
2013-08-07 22:48:11 +08:00
Louie Dinh
5617b28048
Expand on References. Add Books.
2013-08-05 17:54:50 -07:00
ldinh
d2f0d8222e
Fix typo
2013-08-05 17:42:38 -07:00
Adam
9ad61b5586
Authors -> Contributors
2013-07-03 22:59:13 -07:00
Adam Bard
7ec9e44ef0
Merge pull request #99 from adelq/master
...
Fix minor grammatical error on python page
2013-07-03 15:31:18 -07:00
Adel Qalieh
2954fc9bb5
Fix grammatical errors
2013-07-03 18:20:03 -04:00
Adam
aa66a13d49
Small fix in python
2013-07-03 08:49:29 -07:00