Ruby Essential Training Part 1: The Basics

Ruby Essential Training Part 1: The Basics

4h 16mIntermediate2022-03-10

Authors

Kevin Skoglund

Kevin Skoglund

Founder of NovaFabrica

Course details

Ruby, the popular object-oriented open-source programming language, is a great place to start learning programming or web development. You can use it to write interactive programs or build scripts to speed up common tasks. In this course, instructor Kevin Skoglund provides the basics that new and experienced developers need to know to start coding with Ruby, starting with the core object types: numbers, strings, symbols, booleans, and more. He demonstrates Ruby's control structures, including conditionals, loops, and iterators. Kevin explains scripting best practices and shows the power of using enumerables and code blocks. By the end of the course, you should be able to use Ruby to define your own custom methods with loops and conditional logic.

Skills covered

RubyEssential TrainingProgramming LanguagesOpen SourceSoftware Development

Concepts

Introduction

  • Learn the basics of Ruby
  • Get the most out of the exercise files

Get Started with Ruby

  • Introducing Ruby
  • Install Ruby on a Mac
  • Install Ruby on Windows
  • Using Ruby
  • Interactive Ruby Shell (IRB)
  • Documentation

Ruby Object Types

  • Objects
  • Variables
  • Numbers - Integers
  • Numbers - Floats
  • Strings
  • Strings - Escaping and interpolation
  • Arrays
  • Array methods
  • Hashes
  • Symbols
  • Booleans
  • Ranges
  • Constants
  • Nil
  • Challenge - Roman numerals
  • Solution - Roman numerals

Control Structures

  • About control structures
  • Conditionals - if, else, elsif
  • Conditionals - unless
  • Conditionals - case
  • Conditionals - Shorthand operators
  • Loops
  • Iterators
  • Challenge - Blanket patterns
  • Solution - Blanket patterns

Ruby Scripting

  • Best practices
  • Exit a running script
  • Input and output
  • Challenge - Guessing game
  • Solution - Guessing game

Enumerables and Code Blocks

  • Enumerables
  • What is a code block
  • Find methods
  • Map methods
  • Inject methods
  • Sort methods
  • Merge methods
  • Challenge - Ruby blanks
  • Solution - Ruby blanks

Custom Methods

  • Define and call methods
  • Variable scope
  • Arguments
  • Argument default values
  • Return value
  • Return multiple values
  • Challenge - Pig Latin
  • Solution - Pig Latin

Conclusion

  • Next steps
100,000 Toman