Scala for the Impatient and over one million other books are available for Amazon Kindle. Learn more



or
Sign in to turn on 1-Click ordering
Sell Us Your Item
For a $8.40 Gift Card
Trade in
More Buying Choices
Have one to sell? Sell yours here
Start reading Scala for the Impatient on your Kindle in under a minute.

Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.
Sorry, this item is not available in
Image not available for
Color:
Image not available

To view this video download Flash Player

 

Scala for the Impatient [Paperback]

Cay S. Horstmann
4.4 out of 5 stars  See all reviews (33 customer reviews)

List Price: $44.99
Price: $25.35 & FREE Shipping. Details
You Save: $19.64 (44%)
o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o o
In Stock.
Ships from and sold by Amazon.com. Gift-wrap available.
Want it Tuesday, May 28? Choose One-Day Shipping at checkout. Details
Free Two-Day Shipping for College Students with Amazon Student

Formats

Amazon Price New from Used from
Kindle Edition $24.08  
Paperback $25.35  
Shop the new tech.book(store)
New! Introducing the tech.book(store), a hub for Software Developers and Architects, Networking Administrators, TPMs, and other technology professionals to find highly-rated and highly-relevant career resources. Shop books on programming and big data, or read this week's blog posts by authors and thought-leaders in the tech industry. > Shop now

Book Description

March 16, 2012 0321774094 978-0321774095 1

Scala is a modern programming language for the Java Virtual Machine (JVM) that combines the best features of object-oriented and functional programming languages. Using Scala, you can write programs more concisely than in Java, as well as leverage the full power of concurrency. Since Scala runs on the JVM, it can access any Java library and is interoperable with Java frameworks.

 

Scala for the Impatient concisely shows developers what Scala can do and how to do it. In this book, Cay Horstmann, the principal author of the international best-selling Core Java™, offers a rapid, code-based introduction that’s completely practical. Horstmann introduces Scala concepts and techniques in “blog-sized” chunks that 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, packages, imports, exception handling, and more
  • Becoming familiar with object-oriented programming in Scala: classes, inheritance, and traits
  • Using Scala for real-world programming tasks: working with files, regular expressions, and XML
  • Working with higher-order functions and the powerful Scala collections library
  • Leveraging Scala’s powerful pattern matching and case classes
  • Creating concurrent programs with Scala actors
  • Implementing domain-specific languages
  • Understanding the Scala type system
  • Applying advanced “power tools” such as annotations, implicits, and delimited continuations 

Scala is rapidly reaching a tipping point that will reshape the experience of programming. This book will help object-oriented programmers build on their existing skills, allowing them to immediately construct useful applications as they gradually master advanced programming techniques.


Frequently Bought Together

Scala for the Impatient + Programming in Scala: A Comprehensive Step-by-Step Guide, 2nd Edition + Scala in Depth
Price for all three: $90.72

Buy the selected items together


Editorial Reviews

About the Author

Cay S. Horstmann is principal author of Core Java™, Volumes I and II, Eighth Edition (Prentice Hall, 2008), as well as a dozen other books for professional programmers and computer science students. He is a professor of computer science at San Jose State University and a Java Champion.


Product Details

  • Paperback: 384 pages
  • Publisher: Addison-Wesley Professional; 1 edition (March 16, 2012)
  • Language: English
  • ISBN-10: 0321774094
  • ISBN-13: 978-0321774095
  • Product Dimensions: 7.1 x 0.8 x 9.1 inches
  • Shipping Weight: 1.1 pounds (View shipping rates and policies)
  • Average Customer Review: 4.4 out of 5 stars  See all reviews (33 customer reviews)
  • Amazon Best Sellers Rank: #90,838 in Books (See Top 100 in Books)

More About the Author

Cay S. Horstmann is also coauthor of Core JavaServer Faces, Second Edition (Prentice Hall, 2007). Cay is a professor of computer science at San Jose State University, a Java Champion, and a frequent speaker at computer industry conferences.

Customer Reviews

The book is well organized and well written with clear examples throughout. MrNickA  |  8 reviewers made a similar statement
And if you decide to adopt Scala for a project, this book will also help get you going. K. Ferrio  |  7 reviewers made a similar statement
Highly recommended for any serious programmer. Justin du Coeur  |  6 reviewers made a similar statement
Most Helpful Customer Reviews
34 of 36 people found the following review helpful
5.0 out of 5 stars A Pragmatic Tour of Scala for Serious Programmers April 25, 2012
Format:Paperback
For the Impatient:

There's really only one reason to read book reviews, and that's to find out if you should invest your time in another book. The short answer in this case is "Yes!" -- provided you are an experienced programmer seeking greater expressiveness -- and "Yes!" -- if you are have stared in bewilderment at Scala code which seemed like a Byzantine Type Zoo. This book will sort you out and put you on the path to productivity.

For the slightly less Impatient: (Ok, I'm going to run long. I really like the book.)

If you're not using Scala yet but you've been reading about it online, you've probably noticed a lot of discussion and speculation online about which companies and how many people are actually using Scala in production. It's clear that Scala is generating a lot of interest, and similarly clear that many people haven't quite figured out whether Scala is suitable for them and their projects. "Scala for the Impatient" can help you decide for yourself and your teams. And if you decide to adopt Scala for a project, this book will also help get you going.

Let's get one thing out of the way from the start. "Impatient" is not a euphemism for "unprepared." Bring your A-Game. This is a book for programmers who are serious about their craft. It has been intelligently written and carefully edited to enable experienced programmers to quickly learn what's essential and what's extra in Scala. There's no fluff here. If you have little patience for undifferentiated repetition and like the idea that every sentence matters, you're in the right place.

But impatience is not the book's only virtue. As I write this, a wave of Scala books is coming to market. I've read several, most of which I'm unlikely to pick up again. Scala for the Impatient is different, thanks to a unique design and mission. Despite being a young language, a strong dogma seems to have grown up around how Scala is to be taught by books. Not all dogma is bad. But Scala for the Impatient deliberately breaks away from the pack in three remarkable ways:

i) not jumping immediately into functional programming;
ii) thoroughly establishing common ground with experienced Java (and C++) programmers; and
iii) dispatching re-mappable differences before introducing really new concepts

What?!? We could be forgiven for thinking that functional programming is the most important thing about Scala. That might be true, but then why has Scala -- a relative latecomer to the family of functional languages -- generated so much excitement? Perhaps there's more to Scala. Indeed, there is so much more that functional programming makes mostly cameo appearances before finally taking center stage in Chapter 12. That's right: Chapter 12. And I assure you, the first eleven chapters are not slow.

On the contrary, Horstmann swings for the fences on every page, because there's a lot of work to do. Not the least of this work is establishing common ground with experienced Java programmers. If you've ever wondered how much of the "chattiness" of Java is imposed by the JVM, now you know: none of it. Scala is capable of great expressiveness in good hands, so it makes sense to take a fresh look at types, objects and control before applying them functionally. You won't be bored. Like learning a foreign language, you may find that learning Scala gives you a deeper appreciation for the languages you already know.

The third remarkable trait of this book is that Horstmann deliberately addresses what I call re-mappable differences between Java and Scala. Because there is so much genuinely new about Scala, it's important not to be distracted along the way by things which may look new but really are simply remapped. Scala for the Impatient is the only book I've seen so far which demonstrates that the author really understands this. Moreover, Horstmann writes plainly about what you *must* know to be productive in Scala and which are the truly esoteric bits and when you would need them.

I won't read the table of contents to you, but I do want to mention three chapters which really stand out. You've probably heard that Scala has strong support for XML. This gets a whole chapter, and I think you'll be amazed at how natural it feels. Scala makes working with XML fun -- ok, tolerable -- for humans. Another brief but technically solid chapter is devoted to Actors which provide the clean, baked-in concurrency which is a major driver for Scala adoption. And there's even a chapter on the parser library embedded in Scala, which is very useful when you need to parse protocols or storage structures for example. Since parsing theory is a specialty likely unfamiliar to many readers, the essentials are summarized. While the Scala parser library won't replace traditional language recognition tools, its internal domain specific language for parsing may save you from having to jump in and out of Scala for many common tasks.

Finally, the exercises are excellent. Don't skip them! In fact, some of the exercises would make good interview questions.
Comment | 
Was this review helpful to you?
27 of 29 people found the following review helpful
3.0 out of 5 stars No time to learn... just tell me what to do May 6, 2012
Format:Paperback
[Disclosure: I received a free review copy of this book from the publisher.]

My background: I've been a Java developer for twelve years, and I've been following Scala for over four years. I'm not a fanatic about functional programming. My primary interest is in applying Scala in corporate production software development.

"Scala for the Impatient" is to Scala as a recipe book is to cooking. You're not going to learn the basics from it, and you won't learn much of the theory behind Scala, either. It's mostly a collection of short how-to items. The back cover says as much, that it "concisely shows developers what Scala can do and how to do it." In most cases there's no explanation of why something works, how the technique fits into Scala or into various programming styles, what the advantages and limitations are, when you'd want to use it, when you wouldn't want to use it, nor what alternatives you might have.

I have no idea what the purpose of the first few chapters was. They're disorganized grab-bags of mostly the extreme basics (how to call a method) with occasional advanced topics mixed in (implicit conversions and operator overloading, on page 5). If you have even a basic knowledge of Scala, you're not going to learn much until somewhere around Chapter 6. If you're a beginner, these early chapters will leave you totally confused. I'm stunned that the "def" keyword is simply used without any discussion. I'm even more stunned that on page 33 we get, "Alternatively, you could write a.filter(_ % 2 == 0).map(2 * _)" when there'd been no prior mention of closures or anonymous functions, much less the underscore shortcut syntax, nor any mention of the filter and map methods.

Around Chapter 5 or so, the chapters start focusing on specific topics and the book becomes more coherent. Early on there tends to be a problem with organization, where special cases are described first and the topic ends with a description of the everyday usage. This is especially noticeable in Chapter 7 (Packages and Imports), where the chapter drags you through the various ways that you can use nested package definitions before acknowledging that sticking a single package statement at the beginning of the file, the way it's done in Java, "is the preferred notation." Here again, the organization improves in later chapters.

The really good stuff is toward the end, starting at about Chapter 15. Here the chapters are focused on topics that are specialized enough that they're only going to be used on occasion, so there's not as much value in understanding compared with just doing. For example, if you need to write a parser for a domain-specific language, there's not much point in learning all about combinators. You just need to know how to use Scala's combinator parser library, and that's what this book tells you.

Any Scala developer who's trying to write reusable generic classes will run into problems dealing with derived types, and Chapter 17 provides help in heading those problems off. Chapters 18 and 21 show how to deal with even deeper typing problems, plus how to use implicits to make it easier to use your new class library. Understanding the theory behind Scala's type system would be nice, but sometimes you just need to get your danged library working.

"Scala for the Impatient" mostly avoids getting into functional programming. It does, of course, cover closures and the higher-order functions that use them. Beyond that, though, there's not much FP until the latter parts of the book, where there's a glimpse at currying, a sub-section on tail-recursion, a section on higher-kinded types, and a chapter on continuations. The for-comprehension is treated as the equivalent of the Java enhanced for-loop, with a brief mention of the "yield" variation. Other reviewers have also noted the absence of FP cheerleading in this book, which might be even more remarkable than the "for the Impatient" style.

Typical for tech books, the number of typos and factual errors is disappointing (the factual errors are relatively minor and don't significantly diminish the value of the book). It might take a publisher about a year and a half to get a novel into print, but tech books would be obsolete by that time. So they're rushed out the door with a link to the online errata. Unfortunately, the online errata for "Scala for the Impatient" also has typos and errors. Even with the rushing, tech obsolescence already has hit "Scala for the Impatient": Chapter 20 is about actors, but Scala's actors are now essentially deprecated in favor of the Akka library -- Scala 2.10 is currently planned to be the last version containing the actors described in this book.

Also typical for tech books, the index is hit-or-miss. That's particularly unfortunate for a book like this that's mainly a bunch of disconnected tips. The table of contents is going to be the primary tool for locating the desired tips; fortunately, it seems to handle the task pretty well.

Aside from the first few chapters, "Scala for the Impatient" isn't a bad book. But neither is it a great book. I know that different people have different learning styles, and certainly there are those who will appreciate the "just do this and don't ask questions" approach. But for right now I wonder how many people who are considering Scala are the sort who don't want to understand what Scala is about and instead prefer "monkey see, monkey do" recipes. I suspect that by the time a second edition comes out with the typos and errors fixed and -- I would hope -- the first few chapters dropped and the other early chapters reorganized, it'll have a much bigger audience.

The last third of the book, from about Chapter 15 onward, will probably be useful for the Scala programmer who needs to get involved with any of the covered topics: Scala's annotations, XML handling, dealing with the many complications of creating generic libraries in a statically-typed language, parsing of domain-specific languages, the (now deprecated) actor library, creating implicits of various types, and continuations. The middle, Chapters 6 through 14, could be useful to the fairly-new Scala programmer, although I personally don't think the "for the Impatient" style serves well -- I'd rather see a lot more discussion. Chapters 1 through 5 are pretty much a waste of perfectly good trees; although there are a few useful morsels in there, they're hard to find amidst the chaos.
Was this review helpful to you?
15 of 16 people found the following review helpful
5.0 out of 5 stars From the perspective of a Java programmer April 11, 2012
Format:Paperback
I started learning scala "by fire", enjoying the succinctness of the language before really learning what any best practices are, or what it can do--just trial and error. I definitely am happy that I picked up this book, and have learned a lot reading through it. After reading, I feel a lot of refactoring coming on for some of the code I've written.

The information is pretty dense (as you might gather from the title), so I would recommend it for at least an intermediate level programmer. I was a bit shocked to see that the book is ~400 pages, being "for the impatient", but no complaints on the content.

The author continually states "if you're coming from C++/Java, this will make sense to you" or "this might confuse you...", so it seems at least partly aimed toward that audience, which probably makes sense. I felt like I was getting a brain dump customized for me as I read through it.
Was this review helpful to you?
Most Recent Customer Reviews
4.0 out of 5 stars Good Read
Just have to start using it sometime: kind of still stuck on Java for GUI/ Desktop programming; but I got this one because the one by the originator, with the early edition, was a... Read more
Published 29 days ago by Just_Rich
5.0 out of 5 stars Two thumbs up
Nothing detailed to add after all the good detailed reviews above. In short: this is what I wanted Odersky's (sadly too long) book to be: practical, detailed, cheerful,... Read more
Published 1 month ago by John Kerl
5.0 out of 5 stars Clearly and Well Written
it does away with all the fluff and justification for the language and explains the language in good detail. Read more
Published 1 month ago by Greg Mudd
5.0 out of 5 stars Awesome for reference, or just browsing
This book is really good for looking things up with clear concise descriptions.

It's also good for browsing. Scala's a big language. Read more
Published 2 months ago by Jim Fulton
5.0 out of 5 stars Buy this one first
If you are interested in learning Scala, there are several books and online resources that are useful, well-written, and worthwhile. Start with this one. Read more
Published 2 months ago by Jin Choi
5.0 out of 5 stars LOVED IT!
Didn't know any Scala when I started. I was able to breeze through the book and I learnt Scala faster than I've learnt any other language, the reason being that this code presents... Read more
Published 2 months ago by David Barri
5.0 out of 5 stars Delivers on its promise
As a busy IT manager, I found this book to be an invaluable resource. It is easy to read, the examples are useful, and the author does not assume linear reading. Read more
Published 2 months ago by Ronald J. Perrella
5.0 out of 5 stars Scala for the iMpatient
Bought for Christmas for son. He was very pleased and has found the book most useful for this area of programming. He gave it a 5 star rating.
Published 3 months ago by Marilyn Lockyer
5.0 out of 5 stars Solid book for a Scala beginner
I'm a reasonably experienced developer in a few languages, notably java, and found this book easily read and very helpful. Read more
Published 4 months ago by natosaichek
2.0 out of 5 stars Couldn't connect
Just couldn't connect.
Online resources seemed more helpful, in particular [...] Sorry.
I'd also avoid the repetitive comparisons to Java. Read more
Published 4 months ago by Matan
Search Customer Reviews
Only search this product's reviews

What Other Items Do Customers Buy After Viewing This Item?


Forums

There are no discussions about this product yet.
Be the first to discuss this product with the community.
Start a new discussion
Topic:
First post:
Prompts for sign-in
 


Listmania!


So You'd Like to...


Create a guide


Look for Similar Items by Category