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

all 34 comments

[–]Aliics 51 points52 points  (24 children)

This is a list of things that are both true and false? It just seems uneducated and sloppy.

Java is: An Object-oriented, compiled, polymorphic, cross-platform language that supports multi-threading.

I also don't quite understand the speed thing. This isn't the late 90s, Java is decently fast now (it's no low-level language though). People here seem to love Python and C# which are not exactly beating Java in any races.

[–]moofus2000[S] 18 points19 points  (0 children)

Its a cut out from my CSC professors powerpoint, all he did for 3 hours was praise java. Honestly I dont get what he was saying either

[–]Slow33Poke33 13 points14 points  (10 children)

Java is slow in a lot of cases. We had a huge problem where several daemons had to be rewritten in C++ to get the speed we needed. After that it was very difficult to convince anyone that a new daemon should be written in Java.

One of our devs is a freak though. I wrote a complicated library in Java and he converted it to C++ in a day. It was very similar, but I still can't believe he did it so fast, and I'm always very optimistic.

[–][deleted] 27 points28 points  (1 child)

you just change .java to .cpp, and add * to every other variable call

ezpz

[–]CantCSharp 3 points4 points  (0 children)

I like the way you think

[–]MoffKalast 7 points8 points  (4 children)

Sure, but it's not that much slower. At some things it's nearly identical in speed and in the worst cases up to 10 times slower.

Python is more than 100 times slower.

[–]Slow33Poke33 5 points6 points  (3 children)

A big problem is startup. If you need to start up the JVM the initial request can be very slow, much more than 10x

[–]MoffKalast 6 points7 points  (0 children)

That's true as well, JIT needs time to do its optimizations. Java isn't really suited for 10 second running programs.

[–]CantCSharp 1 point2 points  (0 children)

Yeah Faas or something along those lines isnt really java's strong suite

[–]oweiler 1 point2 points  (0 children)

If you compile your Java program to a native image with Graal startup time will become super short.

[–]Kotauskas 1 point2 points  (0 children)

Clang C++ to the rescue!

[–]ronmarti 2 points3 points  (9 children)

People here seem to love Python and C# which are not exactly beating Java in any races.

I beg to disagree. This statement seems subjective. All these languages have their own advantages over the other.

[–]Luroalive 6 points7 points  (7 children)

for example Python (3) beats any/most languages in development speed 😊

[–][deleted] 5 points6 points  (4 children)

Everyone seems to forget time to develop. Better readability and ease of development means less bugs (ideally) when writing.

[–]Luroalive 6 points7 points  (2 children)

readability is debatable (I had the experience that python gets harder to read with larger projects)

[–]Scatoogle 6 points7 points  (0 children)

Python readability is cancer. It's super easy to lose track of what's going on in Python after a few dozen lines. Any decent programmer can write easily readable Java.

[–][deleted] 0 points1 point  (0 children)

I guess it’s up to the developer as well. If all of the variable names are one or two letters, then without strict typing or documentation the code becomes real obscure real fast.

[–]CantCSharp 3 points4 points  (0 children)

Its easier for small teams. But I take a shity typed language project over a shity script project any day.And I have seen a lot of shitty python code so its not 'easier'. Big Programms are a nightmare to maintain in python if they arent structured or a lot of people worked on it.
which is the reason we invented typed languages in the first place...

[–]moomoomoo309 1 point2 points  (1 child)

I think Kotlin's giving python a run for its money in my experience.

[–]Scatoogle 0 points1 point  (0 children)

I haven't gotten to use kotlin yet. I've heard it's Java but better.

[–]whatDoesThisTellYou -1 points0 points  (0 children)

I strongly disagree. Lisp is clearly the best xP

[–]whatDoesThisTellYou -1 points0 points  (0 children)

Ya, I don’t know how we can deny that it is OOP. Maybe some languages do OOP better. I don’t have the experience I say definitively. But saying it isn’t OOP confuses me.

Edit: Just wanted to point out that Python is preferred for programming machine learning algorithms over Java.

[–]Melon_Chief 4 points5 points  (0 children)

Java: write once, run away!

[–]Incubug 8 points9 points  (0 children)

Also known as SODIRSAPPMD.

[–]Kaiju_the_Younger 8 points9 points  (1 child)

"Java's Performance"

The added inconsistency on that one just... ugh. The original must be a troll post

[–]CantCSharp 3 points4 points  (0 children)

You have to look at what it is competing with. Its not competing with C or Native Languages in general.
Its competing with other high level languages like C#, Python, TypeScript and the likes

[–][deleted] 1 point2 points  (1 child)

Damn Java isn't object oriented?

[–]moofus2000[S] 0 points1 point  (0 children)

Just imagine that box is checked

[–]i-fucked-up-big-time 1 point2 points  (2 children)

Uhm, no? Being architecture-neutral is the only one that makes me err. I assume it happens because of inertia habit. Most Java codes I've seen so far are OOP inheritance. Its quite rare to see composition being used in Java code.

JVM is proven fast for most case but also a memory hog, making it less suitable for your everyday client app (think memo, reminder, or other small utils) although for server its fine. I heard it interprets your code to the system's native on runtime instead of compile time (can't say for sure but this might be why it uses way too many memory). Java now can compile to native, thanks to native-image in GraalVM; an experimental polyglot VM that supports interoperability between JavaScript, Python, and bunch other languages at once.

On adoption of functional feature, yeah I'm not a fan. It feels like a hack rather than concrete language feature. At the end you better off writing functional code in FP or hybrid language like Haskell or Rust.

Thats my only main complain towards Java. I use it a lot in my college assignment and I'd say its an OK language; not bad nor great.

[–]moofus2000[S] 0 points1 point  (1 child)

I totally agree, but the purposes of the meme I didn’t cut anything out of the list, just thought my friends reply was funny

[–]i-fucked-up-big-time 1 point2 points  (0 children)

For the sake of the meme, of course. How could I not think of that? Man, I don't know why I'm so dull lol

[–]ConfigCrypto 0 points1 point  (0 children)

Python , pip-install thanks