We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
HackerRank Home
  1. Skills Directory
  2. Ruby
Ruby

Ruby

Basic

Ruby is an interpreted, dynamic, open-source programming language with a focus on simplicity and productivity. Ruby focuses on POLA (Principle of Least Astonishment), meaning it aims to minimize confusion for experienced users. 

This competency area includes exploring the basics of Ruby programming, including constructors, operators, loops, methods, and objects. Also includes learning to write simple modules, working with Arrays, and input-output, among others. 

Key Competencies:

  1. Basics of Ruby Programming - Installing a Ruby interpreter. Writing a simple Ruby program, running a ruby program. Able to open up Interactive Ruby Console (IRB) and able to run simple commands. 

  2. Ruby’s literal Constructors & Operators - Understanding the basic operations of String, Symbol, Array, Hash & Range, and working with basic arithmetic operators and precedence. 

  3. Control Flow and loops - Conditional code execution using If, If/Else, Case Statements. Unconditional looping using loop/do, Conditional looping using while and until. Looping based on a list of values. 

  4. Methods - Defining methods, calling methods, with or without parameters, arguments, and calling syntax. 

  5. Ruby Objects - Creating simple Classes and objects, instantiating objects, and calling methods on objects. Working with Instance variables, Getter and Setter Methods, attr_reader, atter_accessor, attr_writer. Understanding of simple class inheritance mechanisms. 

  6. Modules - Writing a simple module with methods. Including a module in a class - Include & Extend a module. 

  7. Collections - Arrays - Exploring Array operations such as push, shift, concat, flatten, reverse, join, etc. Executing Simple Array Querying Operations:  size, empty?, include?, count, first, last, sample, etc. 

  8. Input & Output - Reading input from the keyboard and displaying output to console, Reading from and writing to files. 

View all skills
  • Blog
  • Scoring
  • Environment
  • FAQ
  • About Us
  • Support
  • Careers
  • Terms Of Service
  • Privacy Policy

Cookie support is required to access HackerRank

Seems like cookies are disabled on this browser, please enable them to open this website