Quote:
|
Originally Posted by Zhivago
Also, why does the false belief that Java is slow compared to C++ continue to persist? That used to be the case, but not for some time... check out some performance benchmarks sometime you guys.
If it is slower in some cases, it is most likely due to bad programming practices like disregarding the cost of object creation.
|
It's funny, several years ago I wanted to test how much slower Java ran on my computer compared to C. So I wrote a little porgram that looked for prime numbers using the exactsame algorithm in both languages and put a timer around the call. Then I let it run for ~10sec, ~1min and ~30min. They were both almost exactly the same speed.
I don't remember which C compiler I was using, and it may not have been the fastest, but the results still surprised me considerably.