News for hackers. Stuff that matters.
Re:In Python, `[0xfor x in (1, 2, 3)]` returns `[15]` by emmelaich on Tuesday April 13, 2021 @04:32PM (#26798854)
This is amazing to me and I would never have suspected such a thing.

Reminds me of Fortran.

https://arstechnica.com/civis/viewtopic.php?t=862715

Re:In Python, `[0xfor x in (1, 2, 3)]` returns `[15]` by PhantomGremlin on Tuesday April 13, 2021 @06:01PM (#26799910)
Yeah, FORTRAN made some bad choices. In its defense, it first appeared in 1957. There wasn't much language design or compiler writing knowledge back in those days.

When we were in college learning FORTRAN, students would ask for help from the teaching assistants at the computer center. One big problem was FORTRAN allowed horrible spaghetti code because GOTO statements could be used anywhere. It was easy to jump into and out from loops. The TAs had a tough job.

It didn't help when people would deliberately mess with the TAs by asking about code with language features similar to those in the article you linked. Something like IIRC after 47 years:

      DO 15 I = (1, 100)
         purported loop stuff goes here
   15    final statement of loop
That is also not a loop control statement. Instead it is an assignment to a complex number.