Ruby tutorial
Ruby is an open source server-side scripting language for object-oriented programming, designed and developed by Matsumoto Hiroshi / Yukihiro Matsumoto of Japan in the mid-1990s. Matsumoto is also known as Matz in the Ruby community. Ruby can run on a variety of platforms, such as Windows, MACOS, and various versions of UNIX.
With this tutorial, you will have a comprehensive understanding of Ruby.
Who is suitable for this tutorial?
This tutorial helps beginners understand the basics and concepts of the Rubylanguage.
What you need to know before reading this tutorial:
Before you begin to practice the examples provided in this tutorial, it is best to have a basic understanding of computer programs and computer programming languages, which will help you learn this tutorial.
Compile/execute Ruby programs
For most programming languages, the first example to get started is “Hello World!”. The following example uses Ruby to output “Hello World!”:
Example
#!/usr/bin/rubyputs"Hello World!";
Or in irb
interactive command line mode:
>>puts "Hello, world!"
Hello, world!
=> nil