Explanation of this Python language feature? [x for x in x for x in x] (to flatten a nested list)

Chris Angelico rosuav at gmail.com
Sat Mar 29 01:08:47 EDT 2014


On Sat, Mar 29, 2014 at 3:40 PM, Mark H Harris <harrismh777 at gmail.com> wrote:
> On 3/28/14 10:51 PM, Steven D'Aprano wrote:
>>
>> You are being patronising to the 94% of the world that is not from the
>> USA. Do you honestly think that people all over the world have been using
>> computers for 30 or 40 years without any way to enter their native
>> language?
>
>
> uh, pretty much.   That's why they called it ASCII American Standard Code
> for Information Interchange...  yup, pretty much. Worked pretty well too,
> for many many years, because so many languages derive from Latin, and most
> non third world countries use Latin derived character sets; yes, although
> missing dieresis and grave and acute accents, &c.

... wow.

Okay. History lesson time.

http://nedbatchelder.com/text/unipain.html
http://en.wikipedia.org/wiki/Code_page

Back before I was born, people were using computers to write messages
that weren't in English. And they managed it, somehow. Can't imagine
how, if all computers work exclusively with seven-bit Latin-derived
character sets.

"Most non-third-world countries use Latin-derived character sets".
Hmm. Let's see. Greece, Russia, China, Japan, Israel, and Egypt are
either third-world or just so insignificant that you can ignore them
and say "most". Yeah, okay, we'll take that as read.

Names are notoriously inaccurate when it comes to internationality.
Ever heard of a place called IHOP? I hadn't, until I started talking
to Americans. What's the difference between "global" and "universal"?
We're clearly taking no notice of Martian languages here, much less
anything outside our solar system. (If humans had non-FTL space travel
five thousand years ago, there could now be colonies all over the
universe, and we wouldn't necessarily even know about them. Those
people would speak languages that can't possibly be Latin-derived;
most likely they'd be derived from Hebrew or Arabic. In the event that
they make contact, we're going to have to allocate some Unicode planes
to them.) "Extended ASCII" is as international as Unicode, just less
standardized.

ChrisA



More information about the Python-list mailing list