- Run the code with:
ruby test_green_eggs_and_ham.rb
- You may only edit the code in the
green_eggs_and_ham.rb
file - Make the first test pass
- You will need to define methods in
green_eggs_and_ham.rb
- You will have to add code to these methods to compute the correct values the tests are indicating.
- Don't just return the number the test expects, write code that works out the answer.
- Remember there are many enumerable methods besides
each
. See if there is an existing enumerable that will help do what you need (along with some code in the block it takes)
- You will need to define methods in
- Remove the 'skip' from the next test in the
test_green_eggs_and_ham.rb
- Repeat previous step until all tests are passing
- Profit
- Have fun