Useful Links
Computer Science
Programming
By Language
Ruby Programming Language
1. Introduction to Ruby
2. Ruby Syntax and Basic Concepts
3. Control Flow and Logic
4. Collections and Data Structures
5. Methods, Blocks, Procs, and Lambdas
6. Object-Oriented Programming (OOP) in Ruby
7. Advanced Ruby Concepts
8. The Ruby Ecosystem
9. Introduction to Ruby on Rails
Control Flow and Logic
Conditional Statements
if, elsif, else
Basic Syntax
Nested Conditions
Multiple Conditions
unless
Syntax and Usage
When to Use unless
case Statements
Syntax and Usage
Multiple Values per When
case with Ranges
case with Regular Expressions
case with Classes
Statement Modifiers
if Modifier
unless Modifier
Inline Conditionals
Loops
while Loop
Syntax and Usage
Loop Conditions
until Loop
Syntax and Usage
Inverse Logic
for...in Loop
Syntax with Arrays
Syntax with Ranges
The loop Method
Infinite Loop Structure
Breaking from loop
Infinite Loops
Creating Infinite Loops
Breaking Conditions
Iterators
each
Array Iteration
Hash Iteration
Block Parameters
times
Numeric Iteration
Index Access
upto
Ascending Iteration
Range-like Behavior
downto
Descending Iteration
Countdown Patterns
map and collect
Transformation Operations
Return Values
select and reject
Filtering Operations
Boolean Conditions
find and detect
Finding Elements
First Match
Loop Control
break
Exiting Loops
Return Values
next
Skipping Iterations
Continue to Next
redo
Repeating Current Iteration
Use Cases
return in Loops
Method Returns
Loop Context
Previous
2. Ruby Syntax and Basic Concepts
Go to top
Next
4. Collections and Data Structures