Created
November 9, 2011 14:24
-
-
Save igrabes/1351571 to your computer and use it in GitHub Desktop.
Secret Santa Program
This file contains hidden or 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
list = Array.new | |
puts "Please enter all of the people that will be participating in this years Secret Santa" | |
while true | |
input = gets.chomp | |
if input == '' | |
break | |
end | |
list << input | |
list_count = list.count | |
end | |
puts "Here is everyone:" | |
# Had to define list_count because the shift method only returns the first object | |
puts list.shift(list_count) | |
puts "Is that everyone?" | |
total_question = gets.chomp | |
if total_question == "yes" | |
puts "Great Here is the output" | |
puts "**I NEED TO WRITE THE CODE FOR THIS**" | |
else | |
puts "Please enter everyone else that you want to be involved:" | |
while true | |
input = gets.chomp | |
if input == '' | |
break | |
end | |
list << input | |
end | |
puts "Here is everyone:" | |
puts list.shift(list_count) | |
puts "Is that everyone?" | |
total_question = gets.chomp | |
if total_question == "yes" | |
puts "Great here are the matchups" | |
puts "**I NEED TO WRITE THE CODE FOR THIS**" | |
else | |
puts "sorry but you need to come back when you get your shit together" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment