Category Archives: RUBY Interview Questions

Float class is used whenever the function changes constantly. It acts as a sub class of numeric. They represent real characters by making use of the native architecture of the double precision floating point. Max is used whenever there is … Continue reading →

Unlike other programming languages ruby deals with extremely large numbers it doesnâ€™t have any barriers. There is no limit on the extent of limit of number usage. Ruby performs this function with two different classes they are fixnum and bignum. … Continue reading →

A class variable starts with an @@ sign which is immediately followed by upper or lower case letter. You can also put some name characters after the letters which stand to be a pure optional. A class variable can be … Continue reading →

There are four different types of variables they are local, instance, global, and class. Variables can be used in the program without any declaration and they can contain data of any type. A local variable contains lower case characters followed … Continue reading →

Classes, variables, methods, constants and modules can be referred by ruby names. When you want to distinguish between various names you can specify that by the first character of the name. Some of the names are used as reserve words … Continue reading →

This function calls a method and it can take any number of arguments and expr. Make sure that you put an asterisk or an ampersand before the expression. Last expr argument can be declared with a hash without any braces. … Continue reading →

Methods in ruby basically perform two functions, named operation and the code present in the class which does a specific function. In Ruby all your algorithms live in methods which inturn is present on objects. Ruby does not have any … Continue reading →

Define operator defines whether a passed expression is defined or not. If the expression is defined it returns the description string or null if the expression is not defined. If a variable is defined it gets initialized. If method_call is … Continue reading →

Like all the modern languages Ruby supports many different operators to its credit. Most of the operators in Ruby are in fact methods due to the object oriented nature of the language. This feature gives Ruby an edge over its … Continue reading →

Following are some of the environment variables used to control the behavior programming of ruby. While programming ENV object lists some of the current variables. RUBYLIB path searches for libraries. Make sure that you separate each path with colons. RUBYOPT … Continue reading →