Command Line
pry -r ./config/app_init_file.rb
- load your app into a pry session (look at the file loaded by config.ru)pry -r ./config/environment.rb
- load your rails into a pry session
Debugger
module Foo | |
class Bar | |
end | |
private_constant :Bar | |
end | |
module Foo | |
p Bar.new # => works fine because we're scoped to Foo |
Command Line
pry -r ./config/app_init_file.rb
- load your app into a pry session (look at the file loaded by config.ru)pry -r ./config/environment.rb
- load your rails into a pry sessionDebugger
// Reference: http://stackoverflow.com/questions/4822471/count-number-of-lines-in-a-git-repository | |
$ git ls-files | xargs wc -l |
A Holiday gift exchange is where a group of people are randomly assigned one other person in the group to buy a gift for. This person can be anyone else in the group except for themselves. Everyone should both give and receive a gift.
Design a program that reads a provided CSV file, performs the matching, and then prints out the matches. Assume that you may email the match to the person later, but focus on printing first.
The format of the CSV is name,email
on each row.