Skip to content

Instantly share code, notes, and snippets.

@AkiraBrand
AkiraBrand / Ruth Brand Technical prework Turing 1806 BE
Last active June 15, 2018 03:16
Day 2 Ruby and Interactive Ruby
What command is entered into the command line to enter an 'irb' session?
To enter an "irb" session (which stands for "Interactive Ruby", simply open your terminal on your Mac and type "IRB"
What is the expression used to express a number squared?
To express a number squared, type in x**2. This tells the calculator to take the number, in this case x, to the power of the number immediately following the two "*" signs.
What is the ruby command used to output something to the terminal?
puts ""
How is a ruby file run from the command line?
using irb, a program that runs ruby code as you type it in. The command to execute is "ruby your_program.rb"
If a # is at the beginning of a ruby line in Atom, what does that indicate?
@AkiraBrand
AkiraBrand / RuthBrand_Prework.md
Last active June 15, 2018 03:20
Turing prework Ruth Brand 1806

Ruth Brand 1806 Back end prework

#day two

What command is entered into the command line to enter an 'irb' session? To enter an "irb" session (which stands for "Interactive Ruby", simply open your terminal on your Mac and type "IRB"

What is the expression used to express a number squared? To express a number squared, type in x**2 . This tells the calculator to take the number, in this case x, to the power of the number immediately following the two "*" signs.