Buy new:
Save with Used - Very Good
Return this item for free
We offer easy, convenient returns with at least one free return option: no shipping charges. All returns must comply with our returns policy.
Learn more about free returns.- Go to your orders and start the return
- Select your preferred free shipping option
- Drop off and leave!

Download the free Kindle app and start reading Kindle books instantly on your smartphone, tablet, or computer - no Kindle device required.
Read instantly on your browser with Kindle for Web.
Using your mobile phone camera - scan the code below and download the Kindle app.
Follow the author
OK
Scala Cookbook: Recipes for Object-Oriented and Functional Programming 2nd Edition
Purchase options and add-ons
Save time and trouble building object-oriented, functional, and concurrent applications with Scala. The latest edition of this comprehensive cookbook is packed with more than 250 ready-to-use recipes and 1,000 code examples to help you solve the most common problems when working with Scala 3 and its popular libraries.
Scala changes the way you think about programming--and that's a good thing. Whether you're working on web, big data, or distributed applications, this cookbook provides recipes based on real-world scenarios for both experienced Scala developers and programmers just learning to use this JVM language. Author Alvin Alexander includes practical solutions from his experience using Scala for component-based, highly scalable applications that support concurrency and distribution.
Recipes cover:
- Strings, numbers, and control structures
- Classes, methods, objects, traits, packaging, and imports
- Functional programming techniques
- Scala's wealth of collections classes and methods
- Building and publishing Scala applications with sbt
- Actors and concurrency with Scala Future and Akka Typed
- Popular libraries, including Spark, Scala.js, Play Framework, and GraalVM
- Types, such as variance, givens, intersections, and unions
- Best practices, including pattern matching, modules, and functional error handling
- ISBN-101492051543
- ISBN-13978-1492051541
- Edition2nd
- PublisherO'Reilly Media
- Publication dateSeptember 14, 2021
- LanguageEnglish
- Dimensions6.75 x 1.75 x 8.75 inches
- Print length799 pages
Frequently bought together

Customers who viewed this item also viewed
From the brand

-
Sharing the knowledge of experts
O'Reilly's mission is to change the world by sharing the knowledge of innovators. For over 40 years, we've inspired companies and individuals to do new things (and do them better) by providing the skills and understanding that are necessary for success.
Our customers are hungry to build the innovations that propel the world forward. And we help them do just that.
-
Your partner in learning
-
Bestsellers
-
Software Development
-
Programming Languages
-
AI / Machine Learning
-
Data Science
-
Data, Databases and more
-
Cloud Services
-
Business
-
Finance
-
Blockchain / Cryptocurrency
-
Security
-
Cookbooks
-
Head First series
-
97 Things series
-
Lean series
From the Publisher

From the Preface
This is a cookbook of problem-solving recipes about Scala 3, the most interesting programming language I’ve ever used. The book contains solutions to more than two hundred fifty common Scala programming problems, demonstrated with more than one thousand examples.
Compared to other Scala 3 learning resources, there are several unique things about this book:
- As a cookbook, it’s intended to save you time by providing solutions to the most common problems you’ll encounter.
- The book covers not only the Scala language but also recipes on Scala tools and libraries, including sbt, Spark, Scala.js, Akka actors, and JSON processing with the Play Framework.
- The book takes a big dive into the Scala collections classes, using five chapters to demonstrate their use.
- Output from the examples is shown either in the Scala interpreter or in comments after the code. As a result, whether you’re sitting by a computer, on a plane, or reading in your favorite recliner, you get the benefit of seeing their exact output. (Which often leads to, “Ah, so that’s how that works.”)
Audience
This book is intended for programmers who want to be able to quickly find solutions to problems they’ll encounter when using Scala and its libraries and tools. I hope it will also be a good tool for developers who want to learn Scala. I’m a big believer in learning by example, and this book is chock-full of examples.
Editorial Reviews
About the Author
Product details
- Publisher : O'Reilly Media
- Publication date : September 14, 2021
- Edition : 2nd
- Language : English
- Print length : 799 pages
- ISBN-10 : 1492051543
- ISBN-13 : 978-1492051541
- Item Weight : 2.84 pounds
- Dimensions : 6.75 x 1.75 x 8.75 inches
- Best Sellers Rank: #1,712,132 in Books (See Top 100 in Books)
- #96 in Functional Software Programming
- #96 in Object-Oriented Software Design
- #455 in Object-Oriented Design
- Customer Reviews:
About the author

Alvin took the circuitous route to software development. He managed to get a degree in Aerospace Engineering from Texas A&M University when all he was really trying to do was play baseball. Once he became a practicing engineer, he realized he liked software and programming more than engineering. So in approximate order he taught himself Fortran, C, Unix, and network administration, sed, awk, Perl, Java, Python, Ruby, JRuby, Groovy, PHP, and Scala.
During this process he started a software consulting firm, grew it to fifteen people, sold it, and moved to Alaska. After returning to the “Lower 48,” he self-published two books (“How I Sold My Business: A Personal Diary”, and “Zen and the Art of Consulting”). He also created alvinalexander.com, which receives millions of page views every year.
These days Alvin is a survivor of two types of cancer and two rare blood diseases. He runs his consulting business, Valley Programming (valleyprogramming.com), and hopes to one day get back to running his 501(c)(3) nonprofit charity, the Zen Foundation (zenfoundation.org).
Customer reviews
- 5 star4 star3 star2 star1 star5 star71%24%5%0%0%71%
- 5 star4 star3 star2 star1 star4 star71%24%5%0%0%24%
- 5 star4 star3 star2 star1 star3 star71%24%5%0%0%5%
- 5 star4 star3 star2 star1 star2 star71%24%5%0%0%0%
- 5 star4 star3 star2 star1 star1 star71%24%5%0%0%0%
Customer Reviews, including Product Star Ratings help customers to learn more about the product and decide whether it is the right product for them.
To calculate the overall star rating and percentage breakdown by star, we don’t use a simple average. Instead, our system considers things like how recent a review is and if the reviewer bought the item on Amazon. It also analyzed reviews to verify trustworthiness.
Learn more how customers reviews work on AmazonTop reviews from the United States
There was a problem filtering reviews. Please reload the page.
- Reviewed in the United States on December 6, 2024Format: PaperbackVerified PurchaseI use this in much the same way as I use an ordinary cookbook -- mostly to be certain of a recipe or to find a new one. Given that all cookbooks reflect the author's taste, it's guidance rather than absolutes but that guidance is correct in the world view of the author. Alexander is a fine author.
To be precise, not everyone has the same view of exactly what consitutes functional programming but the information presented is exactly correct from the author's point of view. If your view is different, you won't find much help here. It's to be expected -- this is a cookbook not a religious tract -- but it would be useful if there were a basic recipe from one of the other points of view if for no other reason than to show the contrast. This is sort of like always presenting raisins as an ingredient in apple pie... it leaves out those whose tradition differs.
Alexander's writing is always worth reading as is this book!