// Command line:
$ ruby -v
// Within irb type "RUBY_VERSION"
# => "2.4.1"
// If using RVM:
$ rvm current
# => ruby-2.4.1
# from code
RUBY_VERSION
# => "2.4.1"
# from command line
$ ruby -v
ruby 2.4.1p111 (2017-03-22 revision 58053) [x86_64-linux]