News for hackers. Stuff that matters.
Re:Python’s tug of war between beginner-friendly and advance... by knighthack on Saturday February 06, 2021 @07:47AM (#26046169)
I have no idea why you would want to declare an x in the loop, and then use it outside the loop. There are better ways of doing things.

The fact that you can do such a thing in JavaScript is exactly why JavaScript is such a mess of a language with its globally-declared and hoisted variables.

That sort of practice has never made sense, and is not a language design that Python should follow.

There are no comments on this comment yet.