Skip to content

Instantly share code, notes, and snippets.

@TrevMcKendrick
Created October 11, 2013 15:16
Show Gist options
  • Save TrevMcKendrick/6936495 to your computer and use it in GitHub Desktop.
Save TrevMcKendrick/6936495 to your computer and use it in GitHub Desktop.
first_line = ["Trevor","Breanna","Annelise","Daniel","Curtis","Robert"]
def take_a_number(line,new_customer)
line << new_customer
first_line = line.length
end
def now_serving(line)
puts "Currently serving " + line.pop
end
def line(line)
line.each_with_index do |person, index|
puts "#{index+1}. #{person}"
end
end
line(first_line)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment