Chris Angelico <ros...@gmail.com>: > Your acceptance of closures is a perfect proof of how magic stops > looking like magic once you get accustomed to it.
Actually, that's a very good observation. You should stick with a smallish kernel of primitives and derive the universe from them. Anyway, functions as first-class objects are truly foundational in all high-level programming. In Python programming, I mostly run into closures through inner classes (as in Java). > If you can accept closures because they just DTRT, why not accept a > much simpler and more obvious operation like putting a 'def' statement > in a loop? Nothing wrong or extraordinary with putting a def statement in a loop, but populating an object with fields (methods) in a loop is very rarely a good idea. Marko -- https://mail.python.org/mailman/listinfo/python-list