The Artima Developer Community


Errata for Programming in Scala, 4th Edition
Chapter 7: Built-in Control Structures
Return to errata index.

Page 83 (PDF page 121):
4ed OReilly Safari (also on page 121 in paperback, 3ed):

"For example, Listing 7.4 shows an alternate way to determine a
greatest common divisor of two numbers."

I guess it should say "the greatest common divisor"; there might be a
number of divisors, but only one can be the greatest.
Page 120 (PDF page 158):
"and captures to greet's unit value result, ()."
it should say:
"and captures the greet's unit value result, ()."

Fixed in 5ed. Tnx.
Page 127 (PDF page 165):
On O'Reilly Safari 4ed:

"This **Array[String]** containing lines is transformed into another
Array[String] containing only trimmed lines that include the substring
"for"."

First appearance of Array[String] uses the wrong font, should use
mono-spaced font.
Page 129 (PDF page 167):
O'Reilly Safari, 4ed (also on page 129, paperback 3ed):

"You can wrap an expression with a finally clause if you want to cause
some code to execute no matter how the expression terminates."

Not really an errata, but a bit misleading. It probably should say "You
can wrap a try-catch expression..." as in the previous paragraph. Or even
better "a try-expression" in both cases, AFAIK catch and finally are
optional clauses subsidiary to a try-expression.

Page number: Book type: Paperback book PDF eBook
Book version: (Or build date. Found on back of title page.)
Your feedback:
Your name: (optional)
Your email address: (optional) (will not be published)

Copyright © 2021 Artima, Inc. All rights reserved.