views:

1016

answers:

7

I would like to learn Scala. In the past, I have used Java and F# extensively.

Would you recommend the book Programming in Scala for someone like me? I really liked the book Expert F#, and I was hoping that Programming in Scala would be in a similar vein, but the few chapters that are online are rather disappointing.

Are there good resources online to learn Scala? I thought the Tour of Scala was great, but a little brief. What else is out there?

+8  A: 

Ahem :-)

Aside from tooting my own horn, I would also recommend you look at The Busy Java Developer's Guide to Scala. Other than those two, I really don't know of many solid Scala introductions. PinS is great, but it's more of a reference / extremely introductory book than a guide for already-knowledgeable developers. There are some offerings coming down the pipe, including (but not limited to) a Pragmatic Programmer's Guide, but they're all a ways off AFAIK.

My recommendation: open up the Scala interpreter shell (or "REPL", if you prefer) and just play around with stuff. I leave it up pretty much all day and try things out as they come to me. It's a remarkably consistent language. Once you get the feel for it, you should be able to intuit the rest with remarkable ease. The interactive shell allows you to test these intuitions with effectively zero overhead.

Daniel Spiewak
+17  A: 

Yes, I can recommend Programming Scala for experienced Java developers. I think it is a very good guide to Scala, especially for Java developers (I'm a 12 year Java veteran).

I have the PDF edition (I have ordered the hardcopy edition as well) and I refer to it on a regular basis. It is very large (754pp) and sometimes hard to find the exact help you need, but for learning Scala, I found it very helpful. There is enough detail on the various aspects of the language and libraries (i.e. closures, for/yield, XML syntax, Combinator Parsing, Scala Swing, type paraemterization) to get you going.

The print edition will be coming out shortly, so you might be able to get a copy from a library or a colleague and evaluate it further before buying.

I'd like to see better (more current) documentation in Wiki format. I personally find the Scala Wiki interface and organization too awkward to work with. The Scala wiki on Wikia may be a better resource once it picks up momentum.

djb
Thanks for your input. I was wondering, do you find that the coding examples in the book are interesting in their own right, or just there to introduce the concepts?
namin
+1  A: 

I bit the bullet and bought the book "Programming in Scala". Though the pace of the book feels slow, it does have interesting moments. So far, I really like the case study of Chapter 18, which designs and implements a simulator for digital circuits, an example from SICP convincingly adapted to Scala.

I found Guido van Rossum's assessment of Scala interesting, as I am still making up my mind about this language.

namin
A: 

Yes. I am an experienced Java developer, and I endorse "Programming in Scala".

In fact, I think it would be a pretty tough slog for a beginning programmer of any sort. Scala is a big, feature rich language, and Programming in Scala addresses a huge scope. It's a very complete book. Fortunately, it works as both instruction and reference.

I'm still pretty new to the Scala world, so I keep the PDF open at all times. That's a compliment to the book more than a reflection on the quality of Scala docs.

mtnygard
A: 

"Programming in Scala" seems hastily thrown together and is hard to read unless you have previous experience with functional programming. If you find the online chapters disappointing, you will be disappointed by the rest, too. They might be technically accurate and insightful, but they are not well written and too academic for the intended audience. I'd recommend the recently published "Beginning Scala" by David Pollak to any Java developer.

Kim
+1  A: 

There's no better book out there than the marvelous Programming in Scala - I bought it a few weeks ago; and have found it to be a good investment. Although as noted by @namin, the book feels a bit slow in the beginning - but once you've got through that initial confusion, you're sailing on the high seas.

Helen Neely
A: 

Just finished reading programming in scala and started on Programming Scala: Tackle Multi-Core Complexity on the Java Virtual Machine. I definitely recommend the Odersky/Spoon/Venners book and Programming in Scala also has the potential to turn out to be a good investment, of both time and money. I like the fact that the programmer states that the book does not cover everything included in Scala, because there already exists a book that does that.

Schildmeijer