w3resource logo
Ruby Exercises

Ruby Exercise practice with solution

Ruby Programming Language

Ruby is a simple and powerful object-oriented programming language, created by Yukihiro Matsumoto.

Like Perl, Ruby is good at text processing. Like Smalltalk, everything in Ruby is an object, and Ruby has blocks, iterators, meta-classes and other good stuff.

You can use Ruby to write servers, experiment with prototypes, and for everyday programming tasks. As a fully-integrated object-oriented language, Ruby scales well.

The best way we learn anything is by practice and exercise questions. We have started this section for those (beginner to intermediate) who are familiar with Ruby.

Hope, these exercises help you to improve your Ruby coding skills. Currently, following sections are available, we are working hard to add more exercises .... Happy Coding!

List of Ruby Exercises

More to Come !

Popularity of Programming Language
Worldwide, Dec 2017 compared to a year ago:

Rank Change Language Share Trend
1 Java 21.5 % -1.4 %
2 Python 19.3 % +5.6 %
3 PHP 8.3 % -1.4 %
4 up arrow Javascript 7.9 % +0.3 %
5 down arrow C# 7.6 % -0.8 %
6 C 6.3 % -0.9 %
7 C++ 6.3 % -0.8 %
8 up arrow R 3.8 % +0.5 %
9 down arrow Objective-C 3.8 % -0.7%
10 Swift 3.0 % +0.2 %
11 Matlab 2.1 % -0.6 %
12 Ruby 1.7 % -0.3 %
13 up arrow VBA 1.4 % -0.0 %
14 up arrow TypeScript 1.3 % +0.2 %
15 Scala 1.2 % +0.2 %
16 down arrow Visual Basic 1.2 % -0.4 %
17 up arrow Kotlin 0.7% +0.9 %
18 down arrow Perl 0.7 % -0.2 %
19 Go 0.7 % +0.2 %
20 down arrow lua 0.4 % -0.2 %
21 up arrow Rust 0.3 % -0.0%
22 down arrow Delphi 0.3 % -0.1 %
23 down arrow Haskell 0.3 % -0.0 %

Source : http://pypl.github.io/PYPL.html

TIOBE Index for December 2017

Dec 2017 Dec 2016 Change Programming Language Ratings Change
1 1 Java 13.268% -4.59%
2 2 C 10.158% +1.43%
3 3 C++ 4.717% -0.62%
4 4 Python 3.777% -0.46%
5 6 up arrow C# 2.822% -0.35%
6 8 up arrow JavaScript 2.474% -0.39%
7 5 down arrow Visual Basic.NET 2.471% -0.83%
8 17 up arrow R 1.906% +0.08%
9 7 down arrow PHP 1.590% -1.33%
10 18 up arrow MATLAB 1.569% -0.25%
11 13 up arrow Swift 1.566% -0.57%
12 11 down arrow Objective-C 1.497% -0.83%
13 9 down arrow Assembly language 1.471% -1.07%
14 10 down arrow Perl 1.437% -0.90%
15 12 down arrow Ruby 1.424% -0.72%
16 15 down arrow Delphi/Object Pascal 1.395% -0.55%
17 16 down arrow Go 1.387% -0.55%
18 25 up arrow Scratch 1.374% +0.19%
19 20 up arrow PL/SQL 1.368% -0.13%
20 14 down arrow Visual Basic 1.347% -0.62%

Source : https://www.tiobe.com/tiobe-index/