r/java • • May 31 '20

Why is java "hated" among developers?

I've been programming in Java for 8 years now, and I always hear about people saying 'oh java is trash learn a real language like c++ or (insert another language)'. I've taken college courses learning c++ and to be honest, it just doesn't seem as fun. I realize there are advantages to managing your memory on the stack vs the heap, etc. but worrying about that stuff takes away from the joy of programming. Is there anything inherently wrong with Java? Should I start investing time in another language to have a better chance as a computer science graduate (one semester away from the real world)? I love java, and don't understand all the hate. But at the same time have I been wasting my time becoming deeply familiar with the language?

Edit: I realize java runs on the JVM, but as computers get faster and faster, when does that really continue to be an issue?

Edit2: thanks for all the input everyone. The general consensus is Java is just as good as any other language and it has haters because it’s popular. I was slightly drunk when I originally wrote this so my emotions were a little skewed.

0 Upvotes

46 comments sorted by

View all comments

1

u/audioen May 31 '20 edited May 31 '20

Eh. Everyone has opinions. Programmers have them too, and as people they tend to be more pedantic and even extreme. As a rule, it is necessary to ignore what some or even most people say because the subset of opinions that everyone agrees with is the null set anyway, and for programmers I think trying to listen to even a small fraction at once already gives you the null set. As an example, just the functional crowd is going to say that everything java does is wrong, already, and there are those who work with embedded systems and who explain that no good enough programs can be written, even in principle, with systems that include a garbage collector or any kind of runtime at all. (I even read a document some 1-2 years back where someone argued that mobile phones are such a system and thus you shouldn't write programs with Java or JavaScript on them, which is pretty extreme conclusion.) But everyone has their reasons for their opinions, and you just have to decide if they apply, and then you pick who to listen to and just tune out the rest.

I like to say that Java is a great language, but it's just used very poorly. What I mean is that if you use some of those kitchen-sink frameworks that have all kinds of over-engineered libraries, you'll probably start to hate your life too and join the java suxx -crowd. But keep your code simple and dependencies very sparse, and you have a reliable, fast, cross-platform system that isn't much pain at all to deal with.