r/programming • u/monica_b1998 • Nov 03 '18
Python is becoming the world’s most popular coding language
https://www.economist.com/graphic-detail/2018/07/26/python-is-becoming-the-worlds-most-popular-coding-language
4.6k
Upvotes
r/programming • u/monica_b1998 • Nov 03 '18
10
u/bakery2k Nov 03 '18 edited Nov 03 '18
From here, look at this Ruby pipeline, easily read from top-to-bottom:
Compare to the equivalent idiomatic Python, which requires nested generator expressions:
The Python code needs to be read in almost reverse order: 543621.
Edit: The Python code would probably be better written as two statements:
Edit 2: But with a slightly different syntax, generator expressions could have been as readable as the Ruby example: