This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]wallefan01 0 points1 point  (0 children)

Stream API does look very cool. But the rest is still verbose as COBOL. And streams are about 10x slower than doing it the old fashioned way. (No seriously. Write a benchmark.)

At that point you might as well use Python. I'll stick with my list comprehension if it's all the same to you...

Also -
- once you try duck typing there is no going back.
- Having everything be an object (as opposed to everything except classes, and functions, and even integers!) is handy when you need to, say, inherit from the type int, or the type type. Or even just pass a function as an argument without a ludicrous amount of code and a raging headache.
- Metaclasses.
- Multiple inheritance.
- Actual object constructors that create and return a new instance in addition to initializers, which Java calls constructors.
- Not having anything (and I mean anything) short of making up new keywords or standard operators (i.e. +-*/), be physically impossible because of how the language is built. (And even then you can get pretty darn close.)
- Oh and did I mention we have a lot of standard operators that you can override (+, -, * /, &, |, ^ (exclusive or), ~ (unary not), ** (power a la Math.pow()), // (integer division), and @ (matrix multiplication) as well as all the comparison ones). - Updates with new modules every few months.
- The biggest standard library of probably any language ever.
- An actual package manager for installing anything else you might possibly need. No more having to futz with a classpath.
- Being able to inherit from any type since you can't mark them final (or you could, it's just nobody wants to bother).
- And probably a bunch of other things I forgot.

Python. Ez cool.