Skip to content

Instantly share code, notes, and snippets.

@RickArora
Last active November 13, 2019 04:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save RickArora/0121924357e34c685e5d89fb83300a7e to your computer and use it in GitHub Desktop.
Save RickArora/0121924357e34c685e5d89fb83300a7e to your computer and use it in GitHub Desktop.
ip-10-24-182-45:ChefApp rickyarora$ ruby chef.rb
Type:
'a' to add a dish
'r' to remove a dish
'd' to display all dishes
'i' to add ingredients to a dish
'q' to quit the program
a
input the name of your new dish
fish
dish added: fish
Type:
'a' to add a dish
'r' to remove a dish
'd' to display all dishes
'i' to add ingredients to a dish
'q' to quit the program
d
list of dishes displayed below:
fish
Your list of food is displayed above.
Type:
'a' to add a dish
'r' to remove a dish
'd' to display all dishes
'i' to add ingredients to a dish
'q' to quit the program
i
enter the name of the dish you wish to ingredients to:
fish
"enter the ingredients seperated by a comma for this dish: "
yellow,green
Traceback (most recent call last):
3: from chef.rb:75:in `<main>'
2: from chef.rb:14:in `get_input'
1: from chef.rb:31:in `parse_input'
chef.rb:43:in `add_ingredients': undefined method `ingredients' for nil:NilClass (NoMethodError)
ip-10-24-182-45:ChefApp rickyarora$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment