How to obtain Ruby version info from a program code

Hello,

Is there an API call returning Ruby version on which the code is
running? Eg. the same information which is returned by running "ruby
--version" on command line? I cannot find one.

Thanks,
Karel

···

--
Posted via http://www.ruby-forum.com/.

The constant RUBY_VERSION.

regards,
Jan Friedrich

···

--
Posted via http://www.ruby-forum.com/.

Guest wrote:

The constant RUBY_VERSION.

regards,
Jan Friedrich

Great! Thanks for your fast response :slight_smile:

···

--
Posted via http://www.ruby-forum.com/\.