Ruby By Examples

The book is broken down into sections. Each section deals with a Ruby language theme, giving examples, from basic to advanced. A full list of Ruby methods can be found here.

= Basics =

Strings
Example-001: String Length Example-002: Reversing Example-003: Single substitution Example-004: Global substitution

Numbers
Example-001: Use the times method to run code over and over Example-002: Calculating absolute value

Arrays
Example-001 Example-002 Example-003 Example-004 Example-005

:: (Scope Operator)
Example-001

Example-002

[ ]
Example-001 Example-002 Example-003

<=>
=== != =~ ====

and or
= Intermediate =

Names, Variables, Constants and Symbols
= Advanced =

Sockets
Example-001 Example-002