top of page

java is one of the most efficient programming languages

Updated: Apr 16, 2022

nowadays more and more people get in touch with programming in their spare time, also companies are seeking for software engineers, so the demand for computer software and hardware increases. hardware companies like intel, amd and nvidia list a high revenue in the last years and so do many other software companies like microsoft or apple. [1,2]

although the power consumption has continued to increase, it has started to level off in the last years. there might be a lot of reasons why this is happening like the lockdown, smarter usage and/or the better efficiency of electrical gadgets. [3,4,5]

programs can also vary in speed, energy consumption and memory allocation. in general, one can divide programming languages into three categories like compiled, compiled in a virtual machine or interpreted. in the following table represents results of a benchmark of computational task among 27 different programming languages. [6]

in general one can say that compiler languages are faster than virtual machine compilers and virtual machine compilers are faster than interpreted languages, the same goes for memory usage. regardless this observation, there are a few exceptions.

there are some vm programming languages which outperform some compiler languages, these are java and lisp. getting more attention to java, you can see that it is in the top 5 fastest and also in the top 5 economical programming languages. only 4 programming languages are faster and more efficient and all of them are compiler based. a closer look at the following table shows the ratio between energy and time. this shows even more how efficient some of the programming languages are.

since python is one of the most trending programming languages of the last years, i am surprised that it is one of the slowest and most inefficient languages in this statistics. [7] in comparison with the first place the contrast is even bigger. python is 75 less efficient and 71 times slower than c. to be fair, python is more convenient. it is way easier to write and understand code using python, this might be also a reason why so many youngers choose this language. but based on speed and power consumption this programming language should be the last choice, since it is at the bottom of the chart.









106 views0 comments

Recent Posts

See All
bottom of page