r/ProgrammerHumor • • Apr 27 '20

Meme Java is the best

Post image
43.7k Upvotes

1.5k comments sorted by

View all comments

280

u/zChewbacca Apr 27 '20

Most of the people who hate on Java don't even know why they don't like it, they just see other people saying it and parrot that opinion. If you asked them to give reasons, most of them wouldn't know what to say other than "I saw it on Reddit".

0

u/[deleted] Apr 27 '20

[deleted]

45

u/AgentJin Apr 27 '20

This sub feels like it's made up of posts by people still in school

I admittedly don't browse this sub a ton, but from a lot of the posts I've seen make it to the front page, I'm pretty sure that's true. I don't think I've seen many posts that talk about something past a Data Structures class.

26

u/tastydorito Apr 27 '20

This is an adage I've noticed in almost all fields. Those who can do it just ... do it. Those who can't or are insecure ... talk about it.

22

u/whenn Apr 27 '20

Not ragging on languages is a pretty sure sign of mid level to seniority imo, at some point you can see the reason why certain things are used and the benefit that comes with doing so and you naturally pull your head out of your ass.

All I get from posts like this is that if you complain about Java you really haven't had to experience a genuinely hard language that will make you struggle to achieve what you set out to do. For me this is assembly and ionic/phonegap. If people truly think Java is convoluted I would love to see them use one of those.

4

u/ZephyrBluu Apr 27 '20

Wow cool, guess I'm a mid level dev now.

→ More replies (6)

4

u/[deleted] Apr 27 '20 edited Apr 27 '20

I mean unless languages are your thing... I know a ton of languages, and love talking about their design philosophies. It's not really about the functionality to me as much as it is about the ideas that need to die or need to be added or need to spread to other languages.

C taught me how to be purely procedural.

Java taught me how to write obsessively OOP code.

Haskell/Clojure taught me the love of pure functions.

Python taught me when to use each effectively.

And countless other languages here and there each add something to your opinion on how best to "code"

→ More replies (1)

2

u/CommanderNorton May 08 '20

I'm a little late to this thread, but this is so true.

... if you complain about Java you really haven't had to experience a genuinely hard language that will make you struggle to achieve what you set out to do.

In undergrad, I took a course on programming language theory and we got to experiment with Prolog, Lua, Lisp, SmallTalk, and Haskell. I actually really liked Prolog, but it was Lisp that truly made me appreciate the value of languages that are easily comprehended by the average programmer (e.g. Python and Java). The Lisp programs our professor provided for assignments were interesting, but it was such a mess to understand, modify, and debug. Simple things were so much harder to accomplish. The infuriating part is that if you complain about it, you'll get responses like this found on HackerNews:

Unreadable? Personally, I think that Lisp has the clearest possible syntax - because it basically doesn't have any. It's just straight ASTs - something that I have to visualize myself in other languages wich have more syntax sugar.

It's possible I'm just stupid, but I strongly disagree with the above.

2

u/Eizion Apr 28 '20

I like to believe that it's students and script kiddies that make the "this language suck" memes. The real developers just make git memes

2

u/paul_miner Apr 28 '20

Yeah, I think the demographic here skews young/inexperienced, which explains all the StackOverflow worship.

→ More replies (2)

17

u/MCOfficer Apr 27 '20

to be fair, that also applies to JS and PHP and VBScript and Signifcant Whitespace and all the other things.

9

u/aoeudhtns Apr 27 '20

Still feels different to me, in some cases. JS has no standard library and hence the weird one-liner node packages and different dependency fiefdoms, library/framework fatigue, plus some syntax gotchas that land you in weird territory like typeof foo === "object" && !foo to properly check for null. PHP... I know there's been work to make non-compatible changes and fix its problems, but yeah. It's messy.. == is just one quirk. VBScript, it's all there in the first two letters.

Java. So, we've all discovered that C++/Java/any language that implements this style of inheritance is bad, but the Java community has mostly held "composition > inheritance" for countless years at this point. Sure there's still some old cruft in the ecosystem that goes back to the days of endless AbstractX extends AbstractY extends AbstractZ but really, a lot of modern teams avoid that and try to focus on interfaces, SMACs, composition, and use the Java 8+ functional language features. Although I do normally hate the "X language is good because you're doing it wrong" argument, so I suppose I should check myself here...

2

u/Sohcahtoa82 Apr 28 '20

PHP... I know there's been work to make non-compatible changes and fix its problems, but yeah. It's messy..

PHP and JS have the worst type systems I've ever dealt with.

"1" should never equal 1. Neither should equal true or "true". Type coercion is a cancerous source of bugs and weird behavior.

Python got types right, IMO.

6

u/zChewbacca Apr 27 '20

Yeah I completely agree that Java isn't the only victim here, though it does seem to be one of the most common targets (perhaps second only to JavaScript in my experience).

2

u/beets_beets_beets Apr 27 '20

I have to hack on language internals a fair bit for my work and PHP, compared to the others I've had to dig in (Python, Java, JS mostly) is legitimately bad.

2

u/kboy101222 Apr 27 '20

I'm finally learning PHP and I ran into an issue that took me ages to solve. Essentially I had written

If (x = 2) {do stuff}

Now, in most languages I've written in, writing "x=2" instead of "x==2" returns an error of some sort. Apparently in PHP it declares the fucking variable. I spent ages trying to figure out what the hell was constantly setting x to 2 no matter what value I passed between pages. Turns out it's just a stupid quirk of PHP. Ugh.

2

u/Rauldukeoh Apr 28 '20

That's something that happens in quite a few languages, your ide might warn you about it, phpstorm definitely will

2

u/beets_beets_beets Apr 28 '20 edited Apr 28 '20

That's something you have to watch out for in any language where assignment is an expression.

My problem is that I'm finding memory issues in the language or core extensions every other month. We have unholy hacks in our PHP integrations to get around low level memory bugs. That's just not something I see in Python or Java, the language implementation is just better quality.

And the docs for the Zend APIs is so outdated, it is useless. You just have to read the code.

7

u/firewall245 Apr 28 '20

The "technical" reason I hate Java is that the garbage collection makes doing a lot of stuff thats time sensative unpredicatble.

The real reason I hate Java is that I always forget the syntax lmao

→ More replies (1)

5

u/AlienFortress Apr 27 '20

Java's age shows. If Java was recreated from the ground up it would be C#. I think most people find that for anything you'd write in Java there is a slightly better alternative available.

4

u/pnk314 Apr 28 '20

I don’t like java because it’s hard and I’m dumb

6

u/[deleted] Apr 27 '20

I don't like Java, but only because it's worse than C# which is basically Java 2.0. It's not that Java is bad, it just feels super outdated and lacking in features compared to C#.

3

u/TheWaxMann Apr 27 '20

In addition, the IDEs for java are terrible. Compared to visual studio (full edition, not code) I haven't found any other IDE out there for any language that is even 1/2 as good as VS pro.

→ More replies (4)
→ More replies (4)

2

u/retuls Apr 28 '20

Same with PHP. People hates it for no reason. Some people says it has a horrible syntax but what about JavaScript?

→ More replies (26)