small medium large xlarge

The latest version of the book is P1.0, released 8 months ago. If you've bought a PDF of the book and would like to update it to this version (for free), visit your home page.

By default this page displays the errata for the latest version of the book. If you have a previous version, select it here:

If you've found a new error, please submit it.

  • Typo
  • Tech. error
  • Suggestion
  • Maybe next edition
  • Not a problem
  • Reported in: P1.0 (30-Mar-20)
PDF page: 8
Paper page: 8
running/Hello.kt <<-- what is that? fun main() = println("Hello World") The above does not compile... If I remove the "running/Hello.kt" it does ...more...
  • Reported in: P1.0 (25-Mar-20)
PDF page: 12
(On Linux) the example using "#!/usr/bin/env kotlinc-jvm -script" doesn't work: /usr/bin/env: ‘kotlinc-jvm -script’: No such file or directory /us...more...
  • Reported in: P1.0 (24-Apr-20)
Paper page: 32
Original: With no arguments the trimmargin() method removes the spaces until the leading | character. Proposed correction: With no arguments the tr...more...
  • Reported in: P1.0 (21-Dec-19)
PDF page: 58
Just above the code iteration/withIndex.kts, the paragraph starts "Alternatively, we can get both the index and the position in one shot". I think it ...more...
  • Reported in: P1.0 (18-Oct-19)
PDF page: 75
In the section called "Wrapping up" it says "Kotlin’s Pair and Triple are useful to create finite small-sized collections. For a larger fixed-sized co...more...
  • Reported in: P1.0 (03-Oct-19)
PDF page: 102

"Thankfully, we have a much better alternatively in Kotlin—reified type parameters."

Should be "alternative"--Jason King

  • Reported in: B11.0 (13-Jul-19)
PDF page: 104
fun <T> findFirst(books: List<Book>, ofClass: Class<T>): T { The first left angular bracket has a different color than right one (fun <T>). Pretty ...more...
  • Reported in: P1.0 (14-Oct-19)
PDF page: 185
Paper page: 168
There's a part on that page that says "Once the expression within the lambda is evaluated, the delegate will memoize the result and future requests fo...more...
  • Reported in: B11.0 (28-Jul-19)
PDF page: 236

Function andThen signature:

in fun <T, R, U> the color of "<T" should be black.--Paolo

  • Reported in: P1.0 (24-Jan-20)
PDF page: 259
In the example dsl/meetingdsl.kts I was trying to complete the example before reading the solution. I came up to a different solution that achieves ...more...
  • Reported in: P1.0 (24-Jan-20)
PDF page: 261
fun main() { val result = html { body { h1 { +"Methods' Behavior" } p { "This is a sample" } } } println(result) } p {...more...
  • Reported in: B11.0 (23-Aug-19)
PDF page: 663
Hi, I am working on a Linux Ubuntu machine. I started reading the chapter about coroutines, but found now to have it work, because I don't know how t...more...