Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # create three arrays with 10 items each:
- # first one is adjective
- # second one is cooking style
- # third one is foods
- # program should randomize food items on its own line
- # each food item is numbered 1. 2. ...
- # creating the 3 arrays
- adjectives = %w(sticky smoky spicy creamy crunchy crispy cheesy glazed flaky buttery)
- cooking_style = %w(deep-fried pan-fried smoked grilled roasted boiled baked braised caramelized seared)
- foods = %w(prime rib rice chicken pizza fish lamb vegetables potatoes bread noodles)
- # randomizing arrays to create menu
- 10.times do |i|
- random_adjectives = adjectives.sample
- random_cooking_style = cooking_style.sample
- random_foods = foods.sample
- puts "#{ i + 1 }. #{ random_adjectives } #{ random_cooking_style } #{ random_foods }"
- end
Add Comment
Please, Sign In to add comment