💎 LearnRuby
Lessons Leaderboard
EN RU
Sign In Sign Up
Lessons Leaderboard
Language: EN RU
Sign In Sign Up
Lessons / Arrays
Module 2 Beginner Ruby 3.4

Arrays

Ruby 3.4

Master Ruby arrays with powerful built-in methods for data manipulation.

Exercise (6)

â—‹
1.

First and Last

Get the first and last elements of an array.

10 points arrays first
â—‹
2.

Double Each

Transform each element in an array.

15 points arrays map
â—‹
3.

Select Evens

Filter an array to keep only even numbers.

15 points arrays select
â—‹
4.

Find Maximum

Find the largest element in an array.

10 points arrays max
â—‹
5.

Symbol to Proc

Learn the &:method shorthand for calling methods on each element.

15 points arrays symbol to proc
â—‹
6.

Find First Match

Use find to get the first element matching a condition.

15 points arrays find

Lesson Info

Beginner
Beginner
Exercise
6
Total Points
80
Ruby Version
3.4
Sign in to start
Back to all lessons

LearnRuby - Learn Ruby 3.4 with interactive exercises