8 ms·
I adore Java! It has been a skill I’ve used at a few jobs now and I wouldn’t want to do anything else. If people get upset about your opinions, then that’s th
by ulkesh 8y ago
I adore Java! It has been a skill I’ve used at a few jobs now and I wouldn’t want to do anything else. If people get upset about your opinions, then that’s their problem.
- GorgeRonde 8y agoMost people who have durably coded in java and say, Haskell or a Lisp (as I have) or any other trending language on HN will prefer the latter. Knowing that (as I did) why not expand your horizon (as I did) ?
- throwawaymath 8y agoI don't see how you could possibly state that conclusively. What leads you to believe most Java programmers would prefer Haskell or some flavor of Lisp? You're saying that people who spend time in both will prefer the latter, but it seems equally plausible that people wouldn't spend time in both because they don't like the latter.
- GorgeRonde 8y agoYour point can be generalized to support any local optimum. Come on. "It seems equally plausible that people wouldn't spend time hearing your argument because they don't like it". Still, this is a bit harsh to return your argument like this, because you're striking a good point: getting to know a language and its "philosophy of use" takes time. However, i do not see why not having taken the energy to climb out of your comfort zone to reach what is considered a better optimum by those who have would give any more weight, by comparison to the alternatives, to your opinion. Edit: I have never used Haskell, but if I had to chose a next language to learn this would probably be it. Simply because people who use it speak of it as a kind revelation by comparison to the the way they used to program in their previous language. Also since I have worked for quite some time with the dynamic alternative in FP (Clojure) I might well try its static variant with Haskell. However as you pointed out, I'm not learning it because of lack of time/focus. Still that does not prevent me from listening closely to what Haskellers have to say, or say people from Common Lisp or even people attached to the JVM and its language ecosystem. Why ? because their experience is valuable. It's not just theirs, and it could way have been mine.
- throwawaymath 8y agoMy point can be generalized, sure. But you haven't substantiated the idea that most people who try both Java and Haskell/Lisp will prefer Haskell/Lisp. That's precisely why my very general point is applicable - your claim is sufficiently unsupported that I can simply reverse the hypothesis and we have no more or less information than we started with. If you'd like, I can trade anecdotes instead - I used to work at a company with a large codebase consisting of nontrivial Java, Clojure, Scala and Haskell. Nearly every engineer I spoke to preferred Java (and I had to interact with nearly all the 300 engineers who worked on it). Now at this point it may seem like I'm being a curmudgeon. But the reason I'm harping on this is because your implicit claim is that Haskell/Lisp are better languages for either productive or aesthetic reasons. But I don't think that's a fair statement - they're different languages, suited to different tasks. You shouldn't draw the conclusion that people who have e.g. moved on to Haskell from Java are representative of most Java developers. It's equally plausible that most Java programmers don't want to move on from Java, and so wouldn't like Haskell if they've tried it. Or perhaps they have tried it and simply didn't jive with it.
- willtim 8y ago> they're different languages, suited to different tasks. What tasks exactly do you think Java is better suited to than Haskell? The "innovation" of Java was to take the runtime of a high-level language and combine it with the productivity of a low-level one. It is not well particularly suited to systems programming or high-level programming (e.g. ML and analytics, parallelism, concurrency).
- deleted 8y ago[deleted]
- koala_man 8y agoI suspect that a lot of programmers actually see programming as a chore, and I think they would prefer Java because it's very predictable and delivers a paycheck. You never hear that point of view though, because they wouldn't spend their time on Hacker News discussing their favorite languages.
- ams6110 8y agoSure, when I first started my professional programming career, I worked in a couple of COBOL shops. Most of the developers there had never used anything else, and weren't interested in anything else. It was a job. Almost all of the programs were some form of "read data from a file, do something with each record, write it back to another file or print to a report." Not much different from assembly line work except more comfortable and paid better.
- watwut 8y agoNo, it is simply not true that java programmers don't likability programming. Quite a few simply like java programming (often due to tools and economic system around it). The idea that everything java is bad, uncool and for lesser programmers was here since java came out. It was not true back then and is not true now.
- preordained 8y agoFor me, I can't let go of my JVM. Clojure is good though.
- mruts 8y agoWhat about Scala? It's probably my favorite language: incredibly expressive, FP+OO, higher kinded-types, great tooling, flexible performance (you can adjust between elegance and java/C++-like performance very easily), and runs on the bullet-proof JVM.
- GorgeRonde 8y agoFor me it's the opposite. I wouldn't let go Clojure ('s standard lib and datastructures) and I don't really care about the JVM !
- madhadron 8y agoI've done significant work in Java and Haskell and some but not huge amounts of production work in Lisp. Writing Java isn't particularly onerous and the tooling is great. That being said, I am told my Java is very unusual: lots of anonymous implementations of interfaces, almost no inheritance, code that feels procedural in its local organization.
- bnolsen 8y agoThat's pretty much modern c++ coding. But more templatization (since there are no interfaces) at this point...
- fsloth 8y agoThat's context sensitive. I love the functional language zoo but the ecosystem is such that for particular problems I prefer still to write C++. Languages have their runtime and their constraints, and there are some areas where maturity, tooling and explicit industry support trumps language quality.
- freeone3000 8y agoHaskell and lisp are cool! But they don't let me stand up a webserver quickly and easily, find some nicely licensed libraries, autocomplete the rest of the code, and be done with the data ingestion website by lunch. express, in node, and ktor, in Kotlin, are simply much faster ways to set up whatever you need than Elixir or Rust or what-have-you. I do my throwaway coding in Java, because it doesn't matter, and my durable coding in Python, because it must be in Python for wide adoption.
- ulkesh 8y agoI have learned many languages. Just because I adore Java doesn't mean I despise everything else. I just happen to prefer it and have no reason, at this time, to use anything else for server-side work.
- hedora 8y agoIn addition to the new trendy languages, I suggest learning modern C++. Java is a good set if training wheels if you want to learn OO patterns. C++’s template system is turing complete, which means its type language is too. That lets you move the vast majority of java runtime type errors to compile time. Moving from Java to modern C++ is analogous to moving from spaghetti Python code to well-structured Java in my book. Also, C++ is extremely well established.
- raverbashing 8y agoSo, I'm curious, what is it about modern C++ that you think is better than Java? Because I know (old) C++, some of the modern stuff and a bit of Java, I don't know the full history.
- badfrog 8y agoOP already said: > That lets you move the vast majority of java runtime type errors to compile time That's a huge win.
- pvg 8y agoIs it? It suggests that typical Java code is for some reason full of run time type errors which it isn't. Whatever the differences between and respective advantages and disadvantages of Java and C++, runtime type errors are just not a some typical Java problem, let alone one that C++ solves.
- koala_man 8y ago>which it isn't NullPointerException is a run time type error and quite common. I'm not convinced it's a problem C++ adequately solves, though.
- pvg 8y agoYou can take a view of types that is broader than the one Java actually uses such that an NPE is a 'runtime type error' but you can do that with lots of runtime errors. It's not what the poster is talking about.
- mruts 8y agoThe people I've met who like Java are the kind of people who don't know any other programming language. In fact, I'm not sure I can think of a worse language than Java. Moreover, when people say the like Java, what they really mean is that they like the JVM.
- noisem4ker 8y agoI've had to study and use my share of programming languages, from C to Haskell. Java is just one of them, and it's the one I like the most. Want to know a language undoubtedly worse than Java? Easy. Append "Script" to it.
- yjftsjthsd-h 8y ago> In fact, I'm not sure I can think of a worse language than Java. COBOL. BASIC, including VBA. Older versions of FORTRAN. All real languages used widely and in production, all far worse than Java.
- a-saleh 8y agoI for one, LOVE both BASIC and VBA :-) But maybe that is just nostalgia speaking, BASIC was my first language :)
- i_am_proteus 8y agoNot sure the Fortran dig is fair. FORTRAN77 was good for the applications it was designed for in 1978. Modern Fortran is still useful for scientific computing.
- yjftsjthsd-h 8y agoI would argue that even for the time early versions were not particularly ergonomic or nice to work with. And yes, I will actually be the first to defend modern Fortran; calling out older versions specifically was a very intentional choice on my part. Granted, I'm unclear on how much the newer variants are used; legacy code bases form a pretty big backlog.
- 8y ago
- willtim 8y agoPeople get upset when the industry fails to make progress and adopt good ideas from academia. Java adopted GC in 1995 and Lambdas in 2014. The rate of progress is frustratingly slow for many. I gave up Java for Haskell 8 years ago and couldn't be happier. In fact, I'd rather switch careers than go back to Java, the productivity and the ad-hoc frameworks would be too painful.
- ulkesh 8y agoThat's great for you. Java works quite well for me and I've had no need to go elsewhere for a server-side language in the last five years. And what do you consider are ad-hoc frameworks? Spring is hardly ad-hoc.
- willtim 8y agoSpring and "aspect-orientated programming" are completely ad-hoc! They use reflection and byte-code generation to implement various forms of runtime magic. This makes reasoning about ones code much much harder. IMHO there are much better ways to solve the dependency and cross-cutting concerns problems, unfortunately Java is not expressive enough to encode them. To be clear, I'm not saying Spring isn't useful, I'm saying the fact that Java needs Spring is unsatisfactory. I wouldn't say my situation is great, most jobs are Java jobs :)