Ruby Backend Dev

Level-up your Backend dev skills

  1. How to Represent "Infinity" in Ruby?

    In certain mathematical calculations or operations you might have the requirement to represent infinity values (i.e. positive infinity or negative infinity) in your code. Find out how you can do that in Ruby.
  2. When to Use the Ruby Array#count Method?

    Learn about the Ruby Array#count method. Find out what it does, and what its different use cases are. Knowing this will help you use it in the right parts of your code.
  3. How to Sort an Array of Ruby Objects by Property in Descending Order?

    Learn how to sort an array of Ruby objects by a specific property in descending order. This step-by-step guide provides clear instructions and code examples to help you organize your data effectively in your Ruby applications.
  4. How to Sort an Array of Ruby Objects by Property in Ascending Order?

    Learn how to sort an array of Ruby objects by a specific property in ascending order. This step-by-step guide provides clear instructions and code examples to help you organize your data effectively in your Ruby applications.
  5. What Is the Ruby Spaceship Operator (<=>)?

    Discover the Ruby spaceship operator (<=>) and its pivotal role in sorting and comparing values in Ruby. Explore how it controls element order in arrays and enables custom comparisons.
  6. How to Define Custom Comparison Logic for "<=>" Operator in Ruby?

    Learn how to define custom comparison logic for Ruby's spaceship operator (<=>). Explore how to create tailored sorting criteria for your Ruby classes, allowing you to control the order of objects based on your specific needs.
  7. How to Count the Number of Elements in an Array in Ruby?

    If you are new to Ruby and you are looking for different ways of getting the total number of elements in an array, then this post might be useful for you.
  8. What's the Difference Between Array #count(), #size() and #length() in Ruby?

    Find out about the differences between the Array#count, Array#size and Array#length methods in Ruby. Knowing this will help you decide which one to use in your code.
  9. How to Get the Length of a Ruby Array?

    Learn the various methods in Ruby to determine the length of an array. Knowing these techniques will help you gain a comprehensive understanding of array length retrieval in Ruby.
  10. How to Convert a Boolean to an Integer in Ruby?

    Ruby does not have a built-in method for converting booleans into integers. Learn about different ways in which you can achieve that in Ruby.
  11. How to Pass an Argument With Ruby Lambda Literal Syntax (->)?

    Learn how to pass arguments with Ruby lambda literal syntax, allowing you to customize and parameterize your lambda functions. Knowing this will help you create lambdas with dynamic inputs.
  12. How to Create a Proc in Ruby?

    Learn about various different ways in which you can create a Proc object in Ruby. Knowing this will help you choose the best one for your specific use case.