Re:Apache loses Java showdown vote to Oracle
by dagw on Tuesday December 07, 2010 @11:01AM
(#1979420)
If you mistype a name, you'll get an error when you run the code.
Depends on the context of the typo. I've had errors along the lines of
bar=False
...
bat=True
...
if bar:
print "Hi"
And wondered why "Hi" was never printed. Of course the problem is hardly unique to Python.
Tis true, python lambdas are lame, but in practice, their use has been mostly superceded by list (and now set and dictionary) comprehensions.
Edit to add: Other dynamic languages have various solutions to the variable declaration problem, usually involving a parser or compiler warning when you use an unbound variable. Python's syntax would have to change to make that possible, I think.
I don't understand. If you mistype a name, you'll get an error when you run the code.