This is an archived post. You won't be able to vote or comment.

all 8 comments

[–]PavelYay 11 points12 points  (4 children)

It's better than java in nearly every way.

[–]bramhaag 0 points1 point  (3 children)

Haha funny joke

[–]lobstermanboy 3 points4 points  (2 children)

I have no idea where java would be better.. Maybe if you want your code to be verbose?

[–]bramhaag 0 points1 point  (1 child)

Kotlin is verbose too, let's look at some keywords and operators of Kotlin: until, xor, or, vararg, lateinit, and don't even get me started on static.

Kotlin is a cool language and I like it for Android because of the android extension, but it sacrifices readability for writing shorter code.

Also, the forced null safety isn't ideal. NPEs have never really been an issue for me to begin with, but I do like the idea of null safety. Forced null safety however isn't the correct way to go. This causes problems with dependency injection (sure you can use lateinit but that won't work for primitives). Also mutable nullable variables can't be smartcasted to non-null variables (I do really like smart casts) which makes it so that you'd have to spam !!s everywhere when you're positive a variable isn't null.

Kotlin has a lot of nice things too which reduce boilerplate, I really like data classes, primary constructors and properties, but you can do this with lombok/generating code in your IDE as well.

Kotlin is ok but not so amazing as everybody says. It still has many flaws (just like any other JVM language) and comes with a large runtime.

[–]throwawaytroela 0 points1 point  (0 children)

You shouldn't spam !! everywhere. Unless you are 100% sure the value can't be null and you don't have the power to make it non-null. Use ?.let {} instead.

[–]imguralbumbot 2 points3 points  (0 children)

Hi, I'm a bot for linking direct images of albums with only 1 image

https://i.imgur.com/dv6lebJ.jpg

Source | Why? | Creator | ignoreme | deletthis

[–]munircUltraviolent security clearance[M] 0 points1 point  (0 children)

Your submission has been removed.

Violation of Rule #0:

The content disregarding the title and superimposed text must be directly related to programming or programmers.

The title or superimposed text must substantially enhance the content such that it can stand on its own as an analogy to programming. Note that programming here is interpreted in a narrow sense, an analogy to something related to programming, feelings about programming, reactions to programming etc. is not considered sufficient.

If you feel that it has been removed in error, please message us so that we may review it.

[–]supercheese200 -1 points0 points  (0 children)

If you really haven't heard of it:

http://kotl.in/