In ruby programming Destructive methods are used to change the object value permanently by itself using bang (!) operator. The exclamation
Category: Ruby Interview Questions
Frequently asked Ruby interview questions
How to get ruby class of an object?
In Ruby programming method ‘class’ is used to get ruby class of an object. Method ‘class’ is used to tells
What is difference between true, nil and false keywords in ruby?
true, nil and false are the keywords in Ruby. In which nil is a special keyword reserved to indicate the absence of value
What is the use of array in Ruby?
An Array is a sequential collection of items, where each item is placed at a unique index or we can
What is class variable?
The two @ characters at the beginning of the variable name is called class variable. See an example below: @@date_today
What is the use of super keyword?
The super keyword calls a method with the same name in the ancestor or ‘super’ class. If the super keyword
How to define class and create objects in Ruby programming?
In Ruby programming, defining class is very simple it is very much similar as in most of OOPs language, simply
What is the use of new and initialize in Ruby Programming?
When a class contains a method named initialize this is automatically called when an object is created using the new
what is called Methods in Ruby?
As name itself tells definition, a method is so called because it provides a method (that is, ‘a way’) for
What is a class instance variable in Ruby?
The Variables starts with the @ character are called instance variables. They belong to individuals’ objects – or instances of
How to right comments in Ruby programming?
Line starts with a # character are treated as comments by Ruby interpreter. So if you want to right comments
What is Ruby on rails?
Ruby on Rails, or simply Rails, is a web application framework written in Ruby under MIT License. Rails is a an impressive framework, providing default structures for
What is Ruby?
Ruby is a cross-platform interpreted language and pure object oriented programming language. Ruby has many features in common with other