Until now, most discussions of Scala have been too abstract, academic, and complex for working programmers. Now, "Scala for the Impatient "concisely shows developers what Scala can do and how to do it. Using Scala, you can write, read, debug, and test programs more easily, as well as leverage the full power of parallelism and concurrency. Moreover, since Scala runs on the JVM, it can access any Java library and integrate with any Java program. So for Java and other object programmers, Scala represents the best of both worlds. In this book, Cay S. Horstmann does for Scala what he did for Java in his global best-seller "Core Java"(TM) He offers a rapid, code-based introduction that's completely practical. Horstmann introduces each Scala concept and technique in "blog-sized" chunks you can quickly master and apply. Hands-on activities guide you through well-defined stages of competency, from basic to expert. Coverage includes Getting started quickly with Scala's interpreter, syntax, tools, and unique idioms Mastering core language features: functions, arrays, maps, tuples, classes, objects, packages, imports, inheritance, files, regular expressions, and more Empowering and extending classes with traits and services Implementing new operators for Domain-Specific Languages and other purposes Working with higher-order functions, collections, and advanced types Leveraging Scala's powerful pattern matching and case classes Creating Scala annotations and interoperating with Java annotations Reading, analyzing, creating, and writing XML Applying advanced "power tools" Actors, Implicits, and Delimited Continuations Scala is rapidly reaching a tipping point that will reshape the experience of programming. This book will help current object programmers build on their existing skills, allowing them to immediately construct useful applications as they gradually master breakthrough functional programming techniques.
Excellent for learning scala basics and interacting with the scala library. I really liked the emphasis on "for" comprehensions in lieu of map/filters. Lots of comparisons with Java throughout the book which is very useful if one is familiar with the java paradigms. The author also provides several pointers on using functional versus object-oriented techniques which can be applied across languages. Would have been great if he delved more into libraries for big data like spark or even walk through using a few popular libraries from scala list.
Very good introduction to Scala for Java Developers. It contains everything you need to know about this exciting language to hit the ground running in a new project. Of course book contains some things that are not necessarily required for a beginner Scala developer, but there are only few of them.
A must read for every Scala developer wannabe with background in Java.
At first, I should acknowledge that it's a good starting book for a java developer who wants to try scala. It covers the basics in a way that java developers get used to, and it's sufficient. It has a good overview of basic data types and collections, object-oriented and functional facilities the language possesses, and it even talks a bit about multithreading.
On the contrary, I don't think it was fair to put the word "Impatient" in the title. Some topics coverage is excessive, for example, they describe all possible import statements in detail despite imports can be easily managed by IDE and, moreover, scala is moving from scala-like imports to more java-like, which makes all time spent on memorizing these rules almost useless.
Moreover, it looks like they had some sort of agreed book size they want to stick to. Some topics were added I don't have any idea why, for example parsing or xml. It's not the best idea to make a reader learn some unpopular libraries for a book meant to be used by the impatient programmer. Maybe they didn't believe someone would read their book to the end? Why then did they add omnipresent implicits and the very end of the book?
The last deficiency of the book to be mentioned, I don't think they cover all complexity of scala types system well. It's too fast to be deep but too complex to be easily understandable. For a java developer, who usually likes to dig into details of generics I think they really could do better.
To conclude, I'll repeat that it's a good book for a start maybe the best I've seen, but it's not enough and it's not perfect. I'm still looking for my perfect scala book, I believe it exists somewhere, I just haven't found it yet.
I've started finally writing some scala at work, so was happy to have the excuse to pick this book up. Scala's an interesting language, and one I'm definitely still learning. This book certainly helped, and I'm sure I'll return to it as I'm actually writing code and thinking about how to organize my work.
This book did a pretty good job of introducing the language and walking you through many aspects, including some features you may or may not need (xml processing, parsers). As I read it, I was thinking about a fun alternative format for the information, sort of a graph of "cards". Each card would be a tidbit extracted from the text, probably with many cards coming from a chapter or even section. After you read a card, you'd be presented with a list of questions, and whichever matched best what question you had ("what's really going on here?" or "is there a cleaner way" or "what would it look like in Java") you would click on to get taken to an appropriate card. You could then track back to whatever point and say "ok, show me the next one", and maybe the system would keep track of what you've seen to know what to show next. At some point I realized that using the REPL was probably just as good as this setup though :)
There were a few points where I found the book to be a bit too quick (or maybe it was just my reading). A mysterious @ operator (or something) made its way into an example, well before another instance with an explanation, and not into the index, and appeared without comment. Later, example code included nested traits, which seem like a thing that could bear some explanation, probably in the chapter on traits, though that didn't seem to be there.
Very good book, it is well organized and teaches you the basics of Scala. I found the chapters on more advanced topics a little lacking, but that's OK since this book is focused on helping introduce you to the language. The examples used in this book get straight to the point and assume the reader has a background in software development. The only downside I found was the kindle version I was reading had formatting issues with the code examples.
I've quickly refreshed my thoughts and notes about the book.
I read this in 2017 when I joined a company that was starting a Java and Scala-heavy project. We delivered an IoT system with really extreme throughput needs. The project continues to this day, serving a fleet of customers in Bulgaria.
At the time, Scala 2.12 was the hot thing. I owe my successful start in Software Engineering to Cay Horstmann's books, and this book is no exception to what I meant to achieve at the time. Its "schoolbook" approach of "topic -> notes -> exercises" really easily teaches you everything you need to know about the language. You don't need to read the chapter sequentially, too, although it's highly recommended.
At my next job in the next 1-2 years, I wrote a proof-of-concept Data Engineering Platform, Schema registries, and whatnot. What was the outcome? Well, it was in the garbage bin. But hey, sometimes you "win", sometimes you learn.
In retrospect, I don't wish Scala upon anyone in 2024. But if you are interested in traits, trying out a significantly more powerful type system without type erasure like in Java, and want to experiment with the Future / Async / Promise model - give it a try!
Oh, and there's a 3rd edition from 2022. Go straight for that one.
Pros: 1. The book gives a short, but comprehensive overview of the language. 2. The book tries to introduce you to the language beyond its syntax: there are chapters on Concurrency, XML, and Grammar Parsing.
Cons: 1. A lot of pointless talking. 2. As of 2021, the 2nd edition is outdated. 3. The book has almost nothing to say about many practical topics: the interpreter version management, the project layout, building, etc. 4. The book is very (but not extremely) didactic, with dummy examples like, "x + y - z", "t match { ... }", "class Pair", etc. 5. A lot of examples aren't reproducible from scratch because you have to import some things to make a snippet work, or you have to bring some logic into a dummy class... IMO, instead of talking that much, the author should've introduced some more working snippets.
Great fast-paced introduction to Scala. Covers a lot of syntax, and new things which Scala does and is advantageous is. This doesn't set out to show you how to build something from scratch, it's mostly theory-based rather than applied, but it's a good reference guide, and first-point for someone not wanting to dive into other books (tomes) on Scala.
Slight gripes, as criticisms are always easier to point out: Could start with how to structure a Scala package/program. Not enough on Scala's advantage in functional programming. Too much of the book compares Scala to Java arguing why the former is advantageous.
The book on a programming language I’ve enjoyed the least (I’m biased since Scala is probably my least favorite programming language). I didn’t like the didactic style: describing how things work without telling why they are useful, throwing a bunch of features at you apparently allowing to achieve the same goal without any guidance on when to pick which, present an example just to tell you that’s not the way you’ll actually write code. This book will not teach you what is idiomatic Scala nor how to write it. And it tested my patience with unnecessary details too many times.
Very good. Honestly, I'd wish that the last 100 pages would have been 200 pages, with more examples and exercises. Also, the chapters on XML and parsing aren't really required, in my humble opinion. At least not if you are really impatient.
However, overall, a very good introduction for Java programmers who want to learn Scala.
Overall, I liked the book and it gives fast and good introduction to Scala. Perhaps I wanted to see also as part of the book, more focus on Functional programming in Scala.
I have read 12 chapters of this book. While the examples are very understandable, and the book succeeds with the key point; to teach Scala features and syntax without being overly verbose, it fails to show how to program in Scala, the examples are simply too short to be satisfactionary. As an example, in Chapter 12: While it had brief coverage on what closures, and other functional programming things are, and how to do it in Scala, it completely failed to drive home the point of the power of functional programming, the discussion was simply to brief for someone who has limited exposure to that line of thinking(e.g programmers coming from Java Background, which this book was primarily aimed at), while personally I understood some of the concepts, having dabbled with JavaScript, I am in no way an expert, and so I was none the wiser on functional programming thinking after completing the chapter. So after Chapter 12 I lost my patience and put it down. I can see it being useful for me as a reference, but not as a first book into Scala. I have decided to try a new book, as of the time writing this I am undecided about which one.
If you are already familiar with object-oriented as well as functional programming concepts, this book will provide a very concise tour of the language, without re-iterating anything you already know.
I bought the book yesterday to get an overview of Scala so that I can talk about it intelligently at some interviews I have coming up. For that purpose it's successful. The book is designed for programmers who are already familiar with Java or C++. In many places where the author could have gone into a lengthy description, he instead says "this is just like this feature you already know, with these differences." That's mostly a successful approach, but there were some places where I found myself wishing for more depth. For example, many of the topics in the Higher-Order Functions and Pattern Matching chapters are things Java and C++ programmers are unlikely to have seen before, and deserved more than a terse single page overview. Also, Section 6.5 on page 74 seems pretty far into the book to first learn that "Every Scala program must start with an object's main method".
A really outstanding lightning tour through the Scala language. My only beef is that it is occasionally too lightning; maybe I am not impatient enough. Trying to cover so much ground so fast means that many concepts are only slightly touched upon and, since the book tends to build on previous parts of the book, this left me asea at times such that I would have to go back and re-read sections as well as go online to figure things out.
However, this is a relatively minor quibble considering the ground covered and the quality of the writing. Overall, I would recommend this to anyone coming from a Java background who wants to see what this Scala thing is all about before diving into some of the beefier texts that are out there.
It worked for me! This was a great way for me to learn Scala. I come from an atypical background, though: I've done plenty of functional and object-oriented programming. I was a bit weak on the Java side of things. But I picked this book up quickly, for the most part. It doesn't waste time introducing you to programming concepts, so it's good for those who have a lot of background. I did find that in the last few chapters, some of the concepts weren't as clearly motivated as early on. I kept wondering why actors were set up the way they were, for example. The model seemed awkward and lacked the static typing considered so important elsewhere. Some historical context of the decades-old actor model would have helped.