Python is wonderful, but the lack of static typing drives me crazy sometimes (which is why I fell in love with Kotlin: best of both worlds). It's almost never a problem, but when the IDE can't tell me, "yup, that's definitely a string, here are all the things you can do with it" and instead tells me "yup, that's definitely some kind of object. Here's a list of functions you've used on it before, including your typo-ed ones, just try something and you'll find out if it actually works at runtime."
It's exploding in use now that it's officially supported by Google for Android programming. It also forces Java best practices by default, which leads to cleaner code. I don't ever want to go back to Java after becoming familiar with Kotlin.
Yeah, Google's policy seems to be "throw everything at the wall and hope something sticks, and occasionally just throw stuff away that people like." Kotlin is developed by JetBrains though and has been around for 7 years already, and they have a strong interest in keeping it around now that it has first-class support on Android. It's even got coroutines now, which are extremely useful in reducing callback hell on Android.
There are a ton of major Android apps and developers that have been using Kotlin in their codebase for years (since they can safely mix Kotlin and Java without having to rewrite any of their codebase), and lots of major libraries are adding Kotlin extensions to their code since it makes writing code so much easier and more concise.
Is there something equivalent for Python like Typescript for JS? I had the same issue with JS but recently picked up Typescript and it really changes the language.
I just encountered a bug that caused a test to fail if I normalised the line endings in the test suite. This was VB. Somehow it caused a multi-line SQL string to be misinterpreted even though it looked identical (just CRLF to LF). I no longer trust these whitespace languages, lol
2.0k
u/Daposto Jul 20 '18 edited Jul 20 '18
Let's remove some enters and spaces in the code to make it cleaner and run it again, did it often haha.