Java has been around for more than 25 years now. Although it is still widely used, a growing number of Java developers are already questioning whether or not Java is still popular. For those who are unfamiliar with Java, it is a computer programming language that runs programs on various devices and platforms, which is very useful in the world of computers. It is used in both commercial and non-commercial applications.
What is Java and why should we care?
Java is a programming language that allows computer programmers to write programs that run on multiple platforms, such as computers, tablets and mobile phones. A lot of software is made using the Java language, which also provides the ability to run the program in multiple languages. Also, Java is used as the programming language for the Android operating system, which allows it to be used on a wide variety of mobile phones.
Java popularity over time
As you can see on image below, Java was popular in the old days, but its popularity is falling down. However, Kotlin community is much smaller, but is growing (not on picture).
Java still runs on more than 90% of all mobile devices. It is not only Android devices which still runs Java, but all the old mobile devices, some laptops. They run Java in a form of Java Virtual Machine — JVM.
Does Java have future?
Java is a very old language. It was brought to life in 1995. It was one of the first programming languages that was designed to be platform independent. But Java is dead and it’s time to give it to the graveyard. There are reasons for that.
- Java is slow.
- It requires a big runtime on your machine to work.
- Java code is hard to read and debug
- It is “bloated” with a big amount of features.
Is Java deprecated in favor of Kotlin?
Since being in development, there are a growing number of developers who are switching to Kotlin, another programming language developed by JetBrains, which has been very well received by programmers. One reason why developers are now looking towards Kotlin is the fact that it is Java compatible, meaning that you can easily switch between Java and Kotlin in a single application to build your program, which would otherwise have required two completely different applications to build the exact same program.
Java for Android OS
A large part of Java is already being used to develop software applications on Android. Kotlin is an improved version of Java, so when Android started to implement Kotlin as its official language, some Java developers began to panic. Some developers even decided to switch to Kotlin because it provided better support for the Android ecosystem.
On 7 May 2019, Google announced that the Kotlin programming language is now its preferred language for Android app developers.
Source: TechCrunch
So, is Java dying?
If you are wondering, will Java die in future, the answer is yes. However, it still will be popular and widely used. What to choose instead? As I wrote before, use Kotlin over Java. In modern projects, Java codebase is considered legacy. Keep in mind that Java knowledge is applicable for Kotlin too.