Java vs Kotlin... the future

Java is good language, I’ve been working with it for more than 20 years. But reality is that big organisation are really slow to adopt new versions and last years I’ve been happy to work at least with Java 8. Comparing to this Kotlin is really a big improvement. Strangely enough it is easier to argue with business to use other language which can be compiled into supported Java version, then get Java version upgrade.

And in general Kotlin have some features, which Java still misses. To name some: null check with ? with possibly to chain and named parameters.


Java code is cumbersome. Kotlin code is always more concise, because it’s a generally well-designed language.
Also too strong bonds between Java language and Java virtual machine is a big mistake - you need to wait for release of a new platform in order to use new features of a language, which sounds ridiculous. In JavaScript it’s even worse, because the compiler is a part of a browser. Kotlin transpiler solves this issues both for JVM and for JavaScript.

1 Like

if we joined PHP + Java we would have Kotlin

not so many languages have worse design than php. definitely bash, but what else?

java carries the burden of legacy. they cannot for example fix weird generics. they never did such a thing and never will. cause of backbard compatibility


I tried to decode the post and give some answers here:

  • Why Kotlin is better than Java? Is everything that Kotlin does also done by Java?
  • Can everything “small that can be done in Kotlin” also be done with Java and its future versions?
    • Yes. You can also use Assembly to do everything you do in Java or Kotlin.
  • Is it a matter of taste if you like to call it “private fun nameMethod (): String {}” instead of “public String nameMethod () {}”?
    • Yes it is. But is it the only difference or is it even an important difference? Come on!
  • Looking at Benchmarks is Java much faster?
    • As a compile time comparison, Kotlin is ~10% slower than Java compile time. For runtime, I couldn’t find a good benchmark but they are head to head. The answer depends on the definition of “much” here. For me it is a no.
  • Would we have Kotlin if we joined PHP + Java?
    • Would we have a 2021 Tesla if we join a 1980 Mercedes with a Scania truck? Maybe. This can even be the starting discussions of Tesla Cybertruck, who knows!
  • How many times since 2004 have you heard the argument WoW killer?
    • I bet it is 32.
  • Ok a bit more serious question: Is Kotlin a Java Killer?
    • No. Java can’t be killed in upcoming decades. It is very hard to kill a language. Even COBOL is not completely dead! Neither Kotlin can be killed anytime soon.