I fixed it. and deebs is not only illiterate (performant is not a fucking word you architect ****) but wrong.
code or gtfo!my code
I'm only very much an amatuer when it comes to java, but it does seem to be an incredibly idiotic language, ... Luckily PHP or Ruby can do most things I need these days.
I'm only very much an amatuer when it comes to java, but it does seem to be an incredibly idiotic language, it is like someone has looked as C++ and thought, hmm, lets get rid of most of the good stuff, make the complex stuff more complicated and lets see if we can make it run 20 times slower while using more ram to do similar tasks. If there is any possible way to avoid it, I try to. Luckily PHP or Ruby can do most things I need these days.
fucking rofl. You're trying to tell me php and ruby are more memory efficient and faster than java (all things like coder skill being equal) ?
Java has it's flaws, but it's great for big complex systems. There's so much tooling out there to support it.
Agreed, working with java is f***ing shit! And so many bad coders using it aswell.
java is certainly much better in terms of dev tools and sure it is faster than the other two, but it is very slow, resource hungry and over complicated considering its C Origins
Basically, once the JVM is running, it will run as fast as or faster than an equivalent C program these days. However: for that to happen the java has to be perfect in terms of memory allocation and object usage etc. But if you're just doing a load of sums, then it's basically the same.
Startup-wise a C program will always beat java cos there's no middle layer to init, it just executed directly on the CPU.
There are cases where C will do better than java, generally around very large scale memory churn - but it's not dramatic. Java can pull ahead massively in a very complicated program because hotspot can collect stats on he fly and use various optimisations that only work if you know the type of data and execution rates going on in your code.
As for ease of writing, you need less code in java, basically. Mainly because of the GC and not having to mop up all your objects, which adds a malloc and a free before and after a lot of things, whereas you just new in java and then make sure you clear all references to it so the GC can sort it out.
Basically, once the JVM is running, it will run as fast as or faster than an equivalent C program these days
---
Generally, you shoulnt be using C unless you have a very good reason, since C++ is better.
---
If you were writing an OS from scratch today, you'd probably use C++.
Chilly,
Real world use here leads me to disagree with your view that once the JVM is running JAVA is fast. It is not.
Java is used internally here for a variety of things (commercial products) and we always find that they require shedloads more RAM and CPU to do the same workload as non-java equivalent in the same application space.
Those are rather frivolous statements.
Real world experience HERE tells me it's shit hot if we want it to be. We serve all our price requests and bet statement requests (up to 70k/sec) purely from java applications that exist in a few gigs of memory across a handful of servers.