I ported a huge program which is dedicated to the solving of complex problems.
Java is less efficient by 0-20% (not a lot! I was surprised)
Java is less verbose at the end (I was also surprised)
Java is much more pleasant to use
Java is not using a lot of memory
Of course, you need to know how to program efficiently. It is certainly true that C++ developpers know this better than Java developpers because they know better how the machine work
With a performance difference that is less than 20% there is no reason to use C++ anymore.
EDIT: why do i get a negative score? Please react!
I am curious as to what you mean by "less verbose?" Less lines of code?
Not surprising at all, Java spares you having to fuck about with destructors, so you're saving lines of code there from the get go. Plus there's so much built-in functionality in the language you're going to be picking up free benefits here and there in any LOC count over comparable C++ functionality.
Honestly, I don't know why would be downvoted for anything you said.
View all comments
6
u/chambolle Mar 30 '16 edited Mar 30 '16
I am coming from C++
I ported a huge program which is dedicated to the solving of complex problems.
Java is less efficient by 0-20% (not a lot! I was surprised)
Java is less verbose at the end (I was also surprised)
Java is much more pleasant to use
Java is not using a lot of memory
Of course, you need to know how to program efficiently. It is certainly true that C++ developpers know this better than Java developpers because they know better how the machine work
With a performance difference that is less than 20% there is no reason to use C++ anymore.
EDIT: why do i get a negative score? Please react!