Chapter 1. Ruby Fundamentals

In 1993, Yukihiro “Matz” Matsumoto combined parts of his favorite languages (Perl, Smalltalk, Eiffel, Ada, and Lisp) to create his own ideal language, which he called Ruby.

Ruby is a dynamic, object-oriented programming language that also supports imperative and functional programming styles. It focuses on simplicity, productivity, and developer happiness. The Ruby website refers to it as “A Programmer’s Best Friend,” and developers with experience in other languages usually find Ruby easy to write and natural to read.

A solid foundation in Ruby is essential to understanding Ruby on Rails, so I’ll cover Ruby fundamentals in this chapter. As we progress through the language features, I’ll demonstrate common ...

Get Rails Crash Course now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.