Code Listings

All of these listings are also available in the book's GitHub repository

Please note that almost all of these listings currently assume running as a KTS scratch file which is not supported by the Kotlin browser plugin that enables these editable & runnable listings.
All listings will be adjusted soon to run as regular Kotlin files and thus work as expected here in the browser.

Switch chapter


Listing0501.kts


Listing0502.kts


Listing0503.kts


Listing0504.kts


Listing0505.kts


Listing0506.kts


Listing0507.kts


Listing0508.kts


Listing0509.kt


Listing0510.kt


Listing0511.kt


Listing0512.kt


Listing0513.kt


Listing0514.kt


Listing0515.kt


Listing0516.kt


Listing0517.kt


Listing0518.kt


Listing0519.kt


Listing0520.kt


Listing0521.kt


Listing0522.kts


Listing0523.kt


Listing0524.kts


Listing0525.kt


Listing0526.kt


Listing0528.kt


Listing0529.kt


Listing0530.kt