Last active
October 15, 2015 10:27
-
-
Save ZASMan/9dd9eea41bf1cb13c041 to your computer and use it in GitHub Desktop.
fav_foods.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def food_array | |
["IceCream", "Pizza", "Rice"] | |
end | |
3.times do | |
puts "Chicken." | |
food_array << gets.chomp | |
end | |
def fav_foods | |
p food_array | |
puts "Your favorite foods are #{food_array.join(", ")}." | |
end | |
p fav_foods | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment