syntax difference

Steven D'Aprano steven.d'aprano at 1
Sun Jun 24 17:28:02 EDT 2018


From: Steven D'Aprano <steve+comp.lang.python at pearwood.info>

On Sun, 24 Jun 2018 16:39:19 +0100, Bart wrote:

> More like utter disbelief at how it works. Surely it cannot work like
> that because it would be too inefficient? Apparently, yes it can...

Apparently, no it doesn't, because the fact that Python is used by tens of
thousands of programmers for some mighty big, performance-critical, projects
proves that it isn't "too inefficient". Its efficient enough.

You want C, and all the headaches and buffer overflows and seg faults it gives,
 you know where to find it.


> I know I'm going to get flak for bringing this up this old issue,

And yet you're going to do it anyway.

> but
> remember when you used to write a for-loop and it involved creating an
> actual list of N integers from 0 to N-1 in order to iterate through
> them? Crazy.

That's nothing, there are languages where the standard way to write a for loop
is to call an external program that generates a stream of numeric strings
separated by spaces in a subprocess, and read the strings from standard input
as text.



--
Steven D'Aprano
"Ever since I learned about confirmation bias, I've been seeing it everywhere."
 -- Jon Ronson

--- BBBS/Li6 v4.10 Toy-3
 * Origin: Prism bbs (1:261/38)



More information about the Python-list mailing list