Live data from Hacker News

If Java Is Dying, It Sure Looks Awfully Healthy

drdobbs.com

281–290 of 327 posts

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#281
post #225

Earlier quoted context omitted.

> Well, there are programming languages and then there are conventions. I think a programming language is more like an alphabet, and programming conventions are the real languages. I like this. As a thought experiment, consider the idea of transforming a convention into another "letter" in the alphabet. A simple example would be the natural numbers. If our alphabet is "a", then we can represent 1 as "a", 2 as "aa", 3…

>> fold ( ) x it should be fold ( ) 1 x or foldr1 ( ) x or foldl1 ( ) x of course according to Guy Steele, fodl and foldr are considered harmful :)

It's really cons lists that are harmful -- foldl and foldr are just ways to operate on them. GP's example would work fine with conc trees and a divide-and-conquer reduce instead.

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#282
post #215

Earlier quoted context omitted.

I have done less than 10 hours of .NET programming in my life so I have no idea here... but my impression is that MONO substantially less accepted than a standard Java port... not trying to bash, just explaining my view. I'm moving a significant production Java app from a Linux box to Windows in the next 3 months. My expected work is about 2-days, and frankly my management wouldn't expect more, and I'd have a hard ti…

I have done less than 10 hours of .NET programming in my life so I have no idea here... but Then don't comment. Your comment is comparing something you know to something you have no idea about. How can anyone legitimately make such a comparison?

I can tell you I've done 10 minutes of C# programming in my life, while addressing a StackOverflow comment, and in that 10 minutes I found something that worked on Microsoft's .NET runtime but not on Mono. You don't need experience to find evidence.

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#283

Earlier quoted context omitted.

Now you're just adding more axioms :)

You mean that "static typing allow better tools"? That's a fact ;) It allows IDEs to do smarter autocomplete, better refactorings, more static error checks, etc.

Here's a dumb analogy to show what I mean:

"You want to switch out the horse? How are you going to get around? Show me something that has at least four legs, can run as fast, eats less and has more stamina!"

The car or the plane looses this comparison.

Point is that all that "stuff" Java programmers are used to might be missing in other languages & ecosystems. And that might be a real issue. But some of that stuff only exists in Java-land to fix issues with Java, and the fact that it's not needed is actually a feature.

I'm sure someone, somewhere, complained that the first cars didn't have feces collection system =)

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#284

Earlier quoted context omitted.

"While systems programmers are fleeing from C++ back to C(!!!)" Example? I know of new developments in systems programming written in C++ (LLVM, clang, WebKit, FireFox (or did that start in C?)), I know of some that moved from C to C++ (gcc, maybe FireFox), I know of new developments in C (Linux, git), but I not aware of any system going from C++ to C. They may exist, but I would need more than a few examples to be c…

Example: microcontrollers and embedded systems. Some time ago there was a shift towards c++,but a large percent are returning back to c. That's what i recall from surveys from UBM, the company that runs eetimes.com .

Looking at http://images.content.ubmtechelectronics.com/Web/UBMTechElec..., I can see where that argument comes from. Looking solely at the C++ data across the years, slides 20 and 21 can be seen as indicators that C++ peaked in 2011. If that's the case, however, C peaked in 2012.

Also, for C, there seem to be fewer 'next' projects than 'current' projects, while for C++ those numbers are about equal.

Extrapolating like mad on almost no data, one could argue that C is on the way out in favour of Python, Java, and C#.

.Net is on the decline, though, so there either must be tremendous growth in the use of Mono in embedded software, or that data must be taken with a grain of salt. My money is on the latter, but surprise me.

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#285

Java may not be dying, but it does take off early on Fridays for golf. Java is not dying the same way Cobol was not dying 10 years ago. It has a lot of legs left but nobody is 'hoping' to use it, they are told to do so. Java is and always has been almost completely a corporate tool. Again, like Cobol, so the 'cool kids' are not going to give it much love. It's too slow to execute to compete with C++, its too slow to…

If Google is a "thought leader" why didn't they use another language for Android?

The more you digg into the languages, the more you see, that Java rules them all... I've tried MANY, MANY languages (from assembler, Basic, Pascal, C, C++, Smalltalk, C#, Python, Ruby/Rails, Groovy, PHP, Perl, awful JavaScript which shouldn't be called a language at all, because it has bugs built in it and many others) and nobody is forcing me to use Java, but I program my Rasberry Pi-s only in Java...

With latest Rasbperian Wheezy where Oracle JDK is included I can tell you it is super cool and super fast for this small ARM processor... I will not use Python on it... Either Java or C - nothing else do I need...

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#286
post #247

Earlier quoted context omitted.

Java is the common, business oriented language of today. How do you you think it's not like the original COmmon Business Oriented Language? It's being used by the same sorts of guys to write the same sorts of apps, no?

Java has some similarities to every programming language including COBOL but it's also totally different. Java is used by a lot of extremely productive programmers and some brilliant apps are written in it.

Same is true of the original COBOL. If you can imagine back as far as the 1960, COBOL and FORTRAN are the cutting edge, every talented and ambitious programmer is trying to get in on this new tech, they are amazed at the productivity and they are writing apps that do hitherto impossible things.

You are no different from them, you were just born a few decades later (same for me). Except, you can look back and learn from their experiences, if you are wise.

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#287

Earlier quoted context omitted.

In C99 it's possible to use compound literals to implement something like named parameters. You create a struct with all of your parameters, and only include the ones you want to set in the compound literal. Anything not explicitly specified in the compound literal gets set to 0, so the caveat is that 0 can't be a valid value for your parameters.

The book 21st century C talks about that trick: http://books.google.fr/books?id=_EdbrocXX9MC&lpg=PA183&ots=D...

Switch .fr to .com: http://books.google.com/books?id=_EdbrocXX9MC&lpg=PA183&ots=...

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#288
post #62
post #52

Earlier quoted context omitted.

It's a natural fit for enterprise programming where time to implement is usually key and logic is endlessly extended to accommodate whatever new business requirements emerge after the last round was deployed. And robustness is valued more highly than raw performance. Use Java - pay for twice the servers and get ten times the uptime? Done. That means that days or weeks spent hunting your latest memory corruption issue…

Yet again I ask what makes java good for high complexity / performance code and get told it's good for managing mediocre programmers.

In the kind of situation GP describes, what matters is probably the well-established practices for extending the behavior of an already-built system without breaking what's already there. A lot of Java practice has built up around having behavior determined dynamically (OOP is a nice fit for that, whereas C does not have great facilities for it). Much of the "ceremony" involved in using the big, complex Java frameworks is about preparing a piece of code for eventual extension. When some behavior is hard-coded in, it's difficult to change later, so the code is parameterized over anything and everything that might eventually change. Of course this looks silly when you do it for small things that won't change -- no need for FizzStrategy and BuzzStrategy interfaces when the only thing you'd ever want to do is print "fizz" or "buzz".

Quite a bit of that programming practice did develop in C++, but Java as a language provides stronger safety guarantees than C++ (lots of memory-related errors are difficult to impossible to have in Java) without sacrificing all that much performance. When you ask for a reasonably performant, statically-typed, memory-safe, object-oriented language, you're going to get pointed at Java (and C#). So that's what people use in that domain.

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#289
post #231

Earlier quoted context omitted.

What are these bigger projects which can only be implemented in java? The linux kernel? Photoshop? Facebook? Or some kind of godawful tiered corporate thing that's big and unwieldy precisely because it's implemented in java?

What are these bigger projects which can only be implemented in java? can is probably an overreach, but I expect the author was referring to the wide range of projects like Hadoop, Solr, etc. If you want static typing, decent performance (and especially if you want a wide range of people who can work on your software) then you have C++/C# or Java. Or you are feeling adventurous or are ex-Google then maybe Golang. The…

> Believe me, godawful corporate things are unwieldy in whatever language they are written in.

No question this is generally true. But note that it's no worse for government than the private sector. The thing that bugs me is that government seems to take the worst aspects of the private sector (e.g. secrecy). If we've built a fabulous claims processing engine, why not give it away to other government departments?

Re: If Java Is Dying, It Sure Looks Awfully Healthy

#290
post #225

Earlier quoted context omitted.

Well, there are programming languages and then there are conventions. I think a programming language is more like an alphabet, and programming conventions are the real languages. I can scroll through code at high speed and understand it at a mere glance once I "get" both the language and the convention that was used (if only the doc and comments didn't get in the way all the freaking time...) Things that feel out of…

> Well, there are programming languages and then there are conventions. I think a programming language is more like an alphabet, and programming conventions are the real languages. I like this. As a thought experiment, consider the idea of transforming a convention into another "letter" in the alphabet. A simple example would be the natural numbers. If our alphabet is "a", then we can represent 1 as "a", 2 as "aa", 3…

Aye, I won't bother critiquing the example, I see what you mean with the boilerplate as noise and part of me agree with you.

One of the main points of programming is to reduce the noise to enable higher levels of code, while keeping an easy access to what's under the hood to fine tune or add new functionalities. A programming language is merely a list of things that will make you lose your temper while you do all that.

Post reply on HN