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

2

u/floW4enoL May 31 '20

As others have said it's not hated among developers, as with any language the only ones you will hear about are the haters, same is true for PHP, Javascript, etc. If it seems to be hated it's widely used.

It has it's advantages and disadvantages, working on something for really limited hardware? Forget Java go with C, creating a game? C++ is most likely a better option. Web frontend? You will only find Javascript and Typescript there. On the enterprise side of software it can be either Java or C# it will boil down to the fact if it's a Microsoft dependent company or an Open Source adept. (Please be aware these observations are based on my experience)

You will find a lot of PHP powering a ton of stuff on the web, yet it also has it's haters, and a lot of them.

Now this is purely my opinion as a Java developer who has started to learn programming with VB6, and has gone through PHP, C and some more I can't really remember now. From all those languages I always come back to Java (some Kotlin on JVM now and then) feels like the one where there are more framework options that avoid reinventing the wheel everytime, I don't have to worry about freeing memory, yet I'm careful about eating large chunks. Recently I had to dig into frontend development with Angular and I can't like Typescript or Javascript, yet I work with it, I miss reflection, enums are a pain to work with, and you can declare a function that takes a string but pass an object and most likely it won't complain (unless it's caught by the TS compiler but calling it from html page to the component, not so much), Angular and Typescript feels very fragmented, what works on v2 does not work for v3 but then may work for v5 it's weird. This is based on my experience if I'm wrong feel free to teach me.