#TeachingKotlin Part 3 - Caveats coming from Java
When you start migrating your Java code to Kotlin, you will encounter multiple subtle changes that might catch you off guard. I’ll document some of these gotchas that I and other people I follow have found and written about. Splitting strings Java’s java.lang.String#split method takes a String as it’s first argument and creates a Regex out of it before attempting to split. Kotlin, however, has two variants of this method. One takes a String and uses it as a plaintext delimiter, and the other takes a Regex behaving like the Java method we mentioned earlier....