Jump to ratings and reviews
Rate this book

Get Programming with Scala

Rate this book
The perfect starting point for your journey into Scala and functional programming.

Summary
In Get Programming in Scala you will learn:

    Object-oriented principles in Scala
    Express program designs in functions
    Use types to enforce program requirements
    Use abstractions to avoid code duplication
    Write meaningful tests and recognize code smells

Scala is a multi-style programming language for the JVM that supports both object-oriented and functional programming. Master Scala, and you'll be well-equipped to match your programming approach to the type of problem you're dealing with. Packed with examples and exercises, Get Programming with Scala is the perfect starting point for developers with some OO knowledge who want to learn Scala and pick up a few FP skills along the way.

Purchase of the print book includes a free eBook in PDF, Kindle, and ePub formats from Manning Publications.

About the technology
Scala developers are in high demand. This flexible language blends object-oriented and functional programming styles so you can write flexible, easy-to-maintain code. Because Scala runs on the JVM, your programs can interact seamlessly with Java libraries and tools. If you’re comfortable writing Java, this easy-to-read book will get you programming with Scala fast.

About the book
Get Programming with Scala is a fast-paced introduction to the Scala language, covering both Scala 2 and Scala 3. You’ll learn through lessons, quizzes, and hands-on projects that bring your new skills to life. Clear explanations make Scala’s features and abstractions easy to understand. As you go, you’ll learn to write familiar object-oriented code in Scala and also discover the possibilities of functional programming.

What's inside

    Apply object-oriented principles in Scala
    Learn the core concepts of functional programming
    Use types to enforce program requirements
    Use abstractions to avoid code duplication
    Write meaningful tests and recognize code smells

About the reader
For developers who know an OOP language like Java, Python, or C#. No experience with Scala or functional programming required.

About the author
Daniela Sfregola is a Senior Software Engineer and a Scala user since 2013. She is an active contributor to the Scala Community, a public speaker at Scala conferences and meetups, and a maintainer of open-source projects.

Table of Contents

Unit 0 HELLO SCALA!
Unit 1 THE BASICS
Unit 2 OBJECT-ORIENTED FUNDAMENTALS
Unit 3 HTTP SERVER
Unit 4 IMMUTABLE DATA AND STRUCTURES
Unit 5 LIST
Unit 6 OTHER COLLECTIONS AND ERROR HANDLING
Unit 7 CONCURRENCY
Unit 8 JSON (DE)SERIALIZATION

560 pages, Paperback

Published September 7, 2021

5 people are currently reading
14 people want to read

About the author

Daniela Sfregola

1 book1 follower

Ratings & Reviews

What do you think?
Rate this book

Friends & Following

Create a free account to discover what your friends think of this book!

Community Reviews

5 stars
3 (33%)
4 stars
3 (33%)
3 stars
1 (11%)
2 stars
2 (22%)
1 star
0 (0%)
Displaying 1 - 2 of 2 reviews
Profile Image for Weekend Critic.
134 reviews3 followers
October 26, 2021
This is not a great book about Scala. It is 500-something pages after which you will have to read another book. It also has almost all of the major flaws of programming books. Feels like someone was playing Bingo.

Key negative points:
- The book goes in-depth and repeats itself on easier topics. On topics that are almost copy paste of Scala docs. There are probably 150 pages total spent on map, flatten and flatMap concepts for each type. Yet, when it comes to complex fundamental topics the book just literally flies through them, at best uses them without explanation, at worst just implies that reader knows a lot about FP or OOP.
- The book spends roughly 1/3 of its volumes on libraries. When, again, not explaining some core concepts in depth. Libraries that rely on complex Scala topics (that are not explained in the book) are thrown in as is in the very beginning of the book.
- The book spends pages on syntax/examples/descriptions of random tasks that are hard to follow. It can define a class and then use it after 20 or so pages. It can spend a whole page on just a copy paste of a code example, of which you are really only interested in 2-3 lines of code.
- The book can have a chapter on a core concept of the language that is not present in other languages. Which is good. And then 3-4 chapters later use some feature of it that was not explained in the original chapter. Literally pointing an arrow at it with 1-2 sentence paragraph about what it is.
- The capstone projects are... weird. 3rd or so capstone project makes you write a REST API using a library that heavily relies on Streams, Encoders and Decoders. And the NEXT chapter after that teaches you what List is (and yes, List is also used in capstone project before it is even introduced)

Overall this is either editorial mistake or the author could not focus on the kind of audience they expected. A book for beginners? Then don't fly over complex fundamental topics. And explain why map methods are so important. No need to copy paste docs for each type even for beginners. A book for experienced engineers? Then go in-depth on complex Scala specific features and don't repeat the syntax of map and flatMap.

The only thing this book can teach is how to solve specific artificial problems given in the book itself. And this is hardly 'teaching' Scala. I rarely give such negative reviews but whether you are a beginner or an experienced engineer I would say avoid this book and don't waste your time.
Profile Image for Louie van Bommel.
13 reviews1 follower
November 7, 2023
Summary: has some very good parts, and even several useful chapters, but the vast quantity is an excessive amount of pasted code of pet projects that won't be of much interest to readers and those projects contain quite advanced Scala working with non-simple libraries. Very little thought went into writing most of this book, it seems, as much of it is either pasted code, or pasted previous parts. This I suppose, was intended to make it seem like complete coverage of a subset of topics, but it's an illusion that's proves to not be very useful for readers who want to learn how to code in Scala.

TBH, the good parts probably deserve maybe as much as 4 stars! Futures, for example was quite good.

I started reading this book, skipping the basic introduction to common coding constructs. At that point, and for many pages, I thought it was a very good book. There were some very good insights in it, and very good material that taught me something.

Then starting with chapters on collections I began to sense that something was not quite right. Maybe reading a little about Lists was not too bad, skimming mostly, because most programmers know a lot about how Lists works already. But after reading about lists, it goes onto talk about other collections, and it does so, I'm convinced, by copying and pasting the same material that was just presented. It is pointeless to read the rest of the book.

There is a point in this book where it starts to become unreadable, and, unless you are interested in an example of using some libraries, you might as well stop reading. For me, and probably for you to, that point is "The Movies Dataset" at the end of the Lists section. From then on, the rest of the book is very unpalatable, and after having trudged through it, I regret having done so.

map and flatMap are repeated excessively in many contexts; it seems that the author has some sort of point to make about them, and I wonderered at one point if the whole point of the book was to lead to some revelation that will take me to a new level of understanding, but there is no revelation, nor really any main point of them that seems to have been made.

For the latter part of the book, my only takeaway is that I might one day want to explore a few of the libraries. (For me, it was specifically Cats Effect). Some code which later piqued my wish to maybe one day explore it (in all fairness) was also using SQL and JSON. However, it's impossible to read the examples, and if I want to read code, I'd go to Github and look at the examples, not a book! I see no point in including literally pages of code interspersed with a few lines of text.

Almost everthing in the book that contains more than 10 consecutive lines of code should have been left out, and literally most of physical contents of the latter half of the book is code. The reason it should have been left out is that, although it might appear to someone who has not read the book, that the author will tell you how to use a library function, but does not do so. What the text between the code basically say is "here is what I did to do my pet project, and this is how I did it". The text in those many projects is no more than what would have been comment statements in actual code. It pretty much teaches nothing.

After having read to the end, I started at the beginning, and, as I expected, I've found the first several chapters to be not useful at all, because, like many "introductory to this language" books, tell you things that are fairly common in all languages. That wouldn't normally be bad, I suppose (but never is useful for me, because I'm not a new programmer, and Scala programmers generally not new programmers), but the majority of the second half of the book really requires way more understanding of programming than a beginner, and even an intermediate programmer can handle.

All in all, don't spend your money on this one, there are better books. "Scala for the Impatient" may be a good choice, but you'll eventually need to read Programming In Scala, Fifth Edition. The latter has too many coding examples of little interest to the general programming population, but it's a must read. And I'm reading "Functional Programming Simplified" by Alvin Alexander, although it's way too long and verbose, but material in it suits me. I still haven't found a decent book that will tea ch you Scala and is suitable for someone who has some experience.

Displaying 1 - 2 of 2 reviews

Can't find what you're looking for?

Get help and learn more about the design.