A collection of exercises and mini projects built while learning Ruby fundamentals. Each file explores different concepts from basic syntax to object-oriented programming.
| File | Description |
|---|---|
calculator.rb |
CLI calculator using lambda functions |
bmi_calculator.rb |
BMI calculator with category ranges |
company_email_generator.rb |
Generates work emails from name and company input |
exam_letter_grading.rb |
Converts grade points to letter grades using case statements |
fibonacci_numbers.rb |
Prints Fibonacci sequence up to a given number |
letter_frequency.rb |
Counts letter frequency in a given text |
palindrome_checker.rb |
Checks if a word is a palindrome — includes both easy and recursive solutions |
search_in_file.rb |
Searches for a keyword across .txt files in the current directory |
syntax.rbandsyntax_intro.rbare personal learning notes — not meant to run, just reference.
| File | Description |
|---|---|
syntax_intro.rb |
Variables, strings, arrays, methods, conditionals, OOP basics |
syntax.rb |
Deep dive into Ruby syntax — operators, hashes, loops, lambdas, modules, exceptions, OOP |
- Variables, strings, arrays, hashes
- Conditionals, loops, case statements
- Methods, lambdas, blocks, yield
- Object-oriented programming — classes, inheritance, encapsulation, polymorphism
- Modules — include, extend, prepend
- File and directory manipulation
- Exception handling
- Recursion
Requirements: Ruby 2.7+
git clone https://github.com/YOUR_USERNAME/ruby_adventures
cd ruby_adventures
ruby calculator.rbThis project was built following the Ruby tutorial by Best Tutorials on YouTube.