First – I am a complete newbie at Ruby. I’ve been looking for resources on learning Ruby for a few weeks – what books to read, what blogs to follow. While I realized that really, other than checking out some basic programs online and really starting to read, there isn’t a good way to get in to any language. However, there are two more problems: most of the suggestions I see for books are of the following format:
- Advanced Developers who have a lot of experience, recommending very advanced books on the subject to Newbies (stupidly)
- Advanced Developers recommending extremely simple books to Newbies, which don’t start them off on the right foot (no fun basically)
I find that the most common question people have about Ruby, or really on any new language is “What should I do first?” To start developing is the answer, but most find that they need to learn the basics before hopping in. However, most (or a very large amount, anyway) of these people are already experienced programmers in other fields, or at least in at least one other language. In fact, this is pretty much exactly what a recent graduate needs – a suggestion on how to properly get started when you know concepts like object programming, and agile development, but hate books that hold your hand like you’ve never programmed before.
So here are the criteria for a good first-time Ruby Programmer who has experience in another language (PHP in my case)
- A Quick basics section that isn’t too deep – I’ll be running through code anyway. Going to ridiculous depth is stupid, since I’ll forget and have to make those mistakes anyway. The basics section should have lots of code examples I can run and play with.
- Fun! I can’t stand the methodical BS that many books have you slog your way through. It’s not good for programming, and it’s certainly not good writing. This might not be the most important factor, but the more fun an activity is the more you get involved, the better you remember, and the faster you learn.
- Good examples – this is paramount. I want code that I can run and see on my machine that isn’t “Oh look, this is what this string prints like. Okay, now let’s concatentate these strings!” This goes hand-in-hand with fun; Better examples brings better understanding and immersion in the language.
- A good flow to advanced, proper suggestions – I need gradual change that goes through proper basics. I can accept some slowness, but I can’t have a huge basics section followed immediately by error handling – what the fuck is that shit about? lol
There. Now, the books:
- Beginning Ruby From Novice to Professional (Peter Cooper)
- The Ruby Programming Language (O’Reilly)
- Ruby Visual Quickstart Guide (Larry Ullman)
Ruby : Visual Quickstart Guide
The first book up. This wasn’t recommended heavily online, but it was one of the first books I grabbed off the shelves. ‘Visual’ sounds good – sadly, visual part seems to have been forgotten outside the cover.
The book starts off well – a quick introduction into the ‘Why?’ of Ruby, and some installation instructions – but then again, perhaps not the most useful, since generally someone who comes looking for the book will already have a reason in mind for why the want to use it. The section on installation instructions is arguably useless, since it is something that can can fall out of date fairly quickly with new releases between OSes, and anyone doing this kind of coding will be advanced enough to find these instructions at more immediate sources online.
The book moves very quickly through the basics – it is quite good at that. It doesn’t go too deep into examples for each topic, but it has at least a few separate cases for every concept, from arrays and ranges to strings and numbers. It also clearly focuses on the object-oriented side of programming without being overbearing about it, which is definitely a positive. By the time it gets to more niche components, such as Gems, the book changes to the deeper descriptions that are necessary for these concepts. It does well to mention databases and compatibilities, as well as a large focus on security – something that is often underemphasized.
Now, the bad – the book is very bland. It is a short book, but nonetheless can feel very sluggish at times. It’s great to be able to skim through the basics sections, but later focuses such as databases and setup are very interdependant, and you are forced to read things you might already know. But the worst is the examples – topical and succinct? Unimaginative and boring. Not a single interesting or lengthy program to test out – everything is the bare-bones basics. While that’s great for someone who is just messing around with new code, the book’s heavy focus on modules and object oriented programming seems to fall apart here.
All-in-all, though, not bad. Not the best book I’ve read, but certainly something I could recommend to someone who is just a beginner, for whom Ruby is their first language. Still, if you are a visual/modular learner, this book’s inadequacies on that front are evident.
This book is a step up from the last. It’s another one by O’Reilly, so it’s pretty standard if you’ve read any of their other intermediate-level books. It starts off very quickly into a primer of Object Oriented Programming – a bit of an annoyance for someone who’s had that drilled into their head day after day, but it moves quickly through it. Then, comes the best part, up front : a multi-page, multi-part, fun program; a Sudoku puzzle solver. It might be silly, but it’s very well-documented and has very well written code. I think it’s a great start for someone who is a visual learner, and it’s great for testing on your own to learn the language.
The next couple chapters crank very quickly through the basics of Ruby, but it’s basically a review – while the other books spend upwards of a hundred pages on these things, this one focuses more into depth than breadth.
However, this is also one of the weak points – it spends a lot of time on abstract concepts that are often deep within basics like ranges, enumerating several specific cases that are not useful to a beginner, but are already obvious to an advanced user. This problem seems to be fairly prevalent – I feel that book writers underestimate the value of trial-and-error, and that while specific, tough issues are important, going to such detail for every concept is unhelpful. In addition, the remaining examples are very poor – line after line of minor variations that, again, mean nothing.
However, like most O’Reilly books, it’s sectioned extremely well. Very little cross-concept paragraphs, and proper segues between sections. Within sections, the book follows by a very clean “Primer – Example – Explanation – Final Example” that works great for reference. Not the best for beginners, but you could get by.
The book might seem very short, but the smaller text size and massive granularity is a definite boon. It does have it’s drawbacks, and while you can survive on a few awesome examples, there’s something to be said for following through. Unlike the previous book, I’d recommend this for someone who is more on the advanced side, or at least has a more distinct familiarity with Ruby. A great reference book as well.
Beginning Ruby : From Novice to Professional
Saving the best for last, because this book kicks ass. Seriously, if you don’t cum in the first three minutes of reading this, then you weren’t getting a blowjob at Barnes and Noble like I was.
The book starts off with an intro that’s both good and bad – it explains why ruby is good, and why you should use it. It’s well-written – but if You’re buying this kind of book book or even just skimming through it, you probably know why you’re looking at it already.
As far as the rest of the book goes, there are no more complaints. After the introduction, there is a short section on object-oriented programming; just quick enough to not annoy anyone experience, but deep enough to cover the important concepts. Then it tears through the basics of Ruby itself, providing lots of small examples along the way – only a few bits of basic code for each.
The book really shines in one particular aspect – every few chapters, there is a large, well-documented and explained piece of software that will compile and run on most ruby setups. It caps off each section of the book very well, and makes it fun to read through it. In addition, it doesn’t leave beginners in the dust, and it means that advanced programmers aren’t too bored.
The best example of this comes at the end of Part 1 – the containing chapter closes with a basic roleplaying game, written in Ruby. It’s a great exercise, and really gets the aspect of ‘fun’ in coding right.
The rest of the book doesn’t slack off, though. After a few chapters on the more advanced concepts of Ruby such as in-depth compiling and debugging, it goes through to describing fully the frameworks that are available to Ruby and something possibly even more important – instructions and explanations on how to start making proper online applications and good UI’s.
There’s even a final section of links and other recommended materials after the appendixes, leading readers to further resources. While this might not be too useful to someone who is already aware of the places and sites they need to go to get this infromation, it gives a good insight into what resources the author felt were useful, and makes it a little easier to understand them.
This is the book that definitely gets my recommendation – and it’s one that you could easily find at your local Barnes and Noble or Border’s bookstore.
If you’re learning Ruby, all three of these books are great. Most of us, though, have specific needs in programming, and not every book is great for that. So enjoy, and I hope this helped you decide your next piece of reading material.


I’m not seeing the obligatory reference to “Why’s (Poignant) Guide to Ruby” listed here. I’m sad because of this. :’(
I see no reference to the Pickaxe book? Is that not the canonical reference, complete with examples?
Can’t forget the pickaxe! Everyone should have a copy who is learning Ruby…
http://pragprog.com/titles/ruby3/programming-ruby-1-9
@Josh – I haven’t read it yet. But it’s available online and is pretty much ubiquitously mentioned, so I skipped it for those reasons as well.
@Allan, Darrin – Pickaxe is too much of a reference – it is not, at any level, good for any kind of general learning. For specific examples, it is great, but that’s not a criteria I look for in this kind of book.
I’ve always looked at the pickaxe book, but according to the review, the APress book seems to evoke more of an experience than a regular read. I guess I’ll pick up both
Nice article!
Hello, I have written a free to use Ruby book : http://is.gd/gLyuf