|
|
|
|
|
by btilly
5049 days ago
|
|
Python has threads. In Python classes are first class objects, and you can easily do anything you could do with Java anonymous classes on the fly. Furthermore Java anonymous classes are usually used as a verbose replacement for a lack of closures. But in Python you can create closures and pass them around. (You do have to do some juggling to mutate variables, but 1 element arrays are only a slight pain to work with.) |
|
Python has green threads, but if you want concurrency, you have to resort to the process module. This is not a limitation Java's threading shares.
I'm not arguing that Python is bad or inadequate, just that it is a fundamentally different thing and should not be viewed as a superset of Java.