aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2018-06-19 12:37:41 -0300
committerSilvio Rhatto <rhatto@riseup.net>2018-06-19 12:37:41 -0300
commitd716dc015ac3433961308859fc09fd4304d725e5 (patch)
tree762481d0772cc1236b35bab2e4fed7a36e3dd264
parentfc893fe2aec6c2fdaa448949752ac8772bdd3554 (diff)
downloadblog-d716dc015ac3433961308859fc09fd4304d725e5.tar.gz
blog-d716dc015ac3433961308859fc09fd4304d725e5.tar.bz2
Updates research/python
-rw-r--r--research/python.md28
1 files changed, 28 insertions, 0 deletions
diff --git a/research/python.md b/research/python.md
index febf01a..dc05e28 100644
--- a/research/python.md
+++ b/research/python.md
@@ -2,6 +2,30 @@
## Learning Python
+### Which version to start? 2.x or 3.x?
+
+Short answer: start learning 3.x and, if needed, check the differences with 2.x.
+
+From [Should I use Python 2 or Python 3 for my development activity?](Should I use Python 2 or Python 3 for my development activity?):
+
+ Besides, several aspects of the core language (such as print and exec being
+ statements, integers using floor division) have been adjusted to be easier for
+ newcomers to learn and to be more consistent with the rest of the language, and
+ old cruft has been removed (for example, all classes are now new-style,
+ "range()" returns a memory efficient iterable, not a list as in 2.x).
+
+ [...]
+
+ In particular, instructors introducing Python to new programmers should
+ consider teaching Python 3 first and then introducing the differences in Python
+ 2 afterwards (if necessary), since Python 3 eliminates many quirks that can
+ unnecessarily trip up beginning programmers trying to learn Python 2.
+
+Also:
+
+* [Python Future: Easy, clean, reliable Python 2/3 compatibility](http://python-future.org/).
+* [Should I learn Python 2 or 3?](https://www.dataquest.io/blog/python-2-or-3/).
+
### General
* Everything is an object. Really? What about symbols like + - and =?
@@ -73,6 +97,10 @@ Python encourages polymorphism:
So remember that when [copying](https://stackoverflow.com/questions/2612802/how-to-clone-or-copy-a-list#2612815)
or referencing a list.
+### Nice stuff
+
+* [Verbose Regular Expressions](http://www.diveintopython3.net/regular-expressions.html#verbosere).
+
## Implementations
* [MicroPython - Python for microcontrollers](http://micropython.org/) ([compiling](https://github.com/micropython/micropython/wiki/Getting-Started).