If you don't want to waste time on installation, you can immediately start writing programs online. Below is a list of links that will allow you to write your programs online.
I recommend installing Ruby on your own computer because later lessons will require it. However, for the first few lessons it does not matter whether you use Ruby installed on your computer or use online tools.
Installation
There are many different methods to install ruby on different distributions. There are too many of them to describe them individually, so I will leave some useful links that will help you through installing Ruby on your computer.
Ubuntu
There are several ways to install Ruby on Ubuntu. Most often, package managers such as rbenv or rvm are used for this purpose, which allow you to quickly change the version of ruby.