https://kotlinlang.org logo
d

Daniel Zayas

10/05/2022, 7:00 PM
JetBrains' Kotlin learning materials & Effective Java & Atomic Kotlin 🧵
Sources: 1. Kotlin learning materials 2. Effective Java 3. Atomic Kotlin 4. Kotlin for Java Developers RE (1), I found the Kotlin Koans course particularly useful for learning syntax as well as some nuances about null safety, equality, and mutable vs read-only collections. RE (2), the course content seems quite similar to Kotlin Koans. RE (3), My first impression of Effective Java is that the recommended patterns are useful for both Java and Kotlin. Some examples: • public static factory methods or builders with private constructors (chapters 1-4) • design for inheritance across package boundaries or, more commonly, prohibit it (chapters 18-19) • prefer interfaces to abstract classes (chapter 20) RE (4), My first impression of Atomic Kotlin is that it's more of a resource for learning syntax (e.g. how to create an abstract class), and less of a resource for learning effective+safe type (e.g. prefer interfaces to abstract classes) Are my first impressions of (2), (3), and (4) way off? Or are they generally consistent with the ways y'all use these learning resources?
g

gildor

10/06/2022, 4:28 AM
I think it was the main goal of Atomic Kotlin, a book for people without prior programming experience, for whom Kotlin is the first language, this why it’s about syntax, or just for people with programming experience, but no related programming experience, this why it covers basic things
🙏 2
Kotlin in Action is also a good book, deeply about language, but also not about practices like interfaces vs abstract classes, though it really need second edition with all new Kotlin features
🙏 2
1
k

Klitos Kyriacou

10/06/2022, 7:53 AM
I think the item numbers have gone out of sequence (it looks like you had item 4 as item 2) but in any case I would agree that Effective Java recommends patterns that are also applicable to Kotlin, but more than that, Kotlin syntax prefers those good-practice patterns, e.g. by making classes final unless you explicitly make them open.
🙏 2
☝️ 1
m

Matteo Mirk

10/06/2022, 9:21 AM
There exists Effective Kotlin book too, so it may be preferable for Kotlin, given the effort Marcin Moskala has put into writing it. — of course Effective Java remains a terrific book
2
🙏 3
d

Daniel Zayas

10/06/2022, 5:31 PM
Kotlin syntax prefers those good-practice patterns, e.g. by making classes final unless you explicitly make them open.
Great example!
There exists Effective Kotlin book too, so it may be preferable for Kotlin
Thank you! I've just purchased the Kindle version.
🆒 1
7 Views