There’s been a lot of action around Kotlin lately. So one question you’ll often hear is “What’s your favorite Kotlin feature?”
And while there are many wonderful things about the language, for me it isn’t about any single technical feature.
My answer? It makes me happy.
Writing code that’s concise, clear, and expressive makes me happy. Focusing on creative solutions to business problems, not boilerplate and ceremony, makes me happy. Feeling an intense motivation to learn, which was missing in the Java days, makes me happy.
And that’s super important. Because being happy isn’t just good for the soul. It’s great for your programming skills too.
As DHH astutely pointed out many years ago in Getting Real:
Would you truly be happy working in this environment eight hours a day? This is especially important for choosing a programming language.
Happiness has a cascading effect. Happy programmers do the right thing. They write simple, readable code. They take clean, expressive, readable, elegant approaches. They have fun.
Imagine extrapolating that feeling over an extended period of time.
The more capable and friendly your language is, the happier you are. The happier you are, the better code choices you make. The better code choices you make, the better habits you build. And the better habits you build, the better programmer you become!
This is exactly what’s happened with Kotlin and me over the past year. And I’m a better programmer because of it.
We found programming bliss in the language Ruby and passed it on to other developers with our framework Rails. Both share a mission statement to optimize for humans and their happiness.
In summary, your team needs to work with tools they love. Choose the fuse that gets people excited. You’ll generate excitement and motivation and a better product as a result.
This is absolutely true for Kotlin— it fits my brain and optimizes for my happiness. Working with it is just flat out fun, exciting, and motivating. It makes the quality of my work better and it makes me better.
I’ve never been a happier (or better) programmer. 😍