Advertisement
Guest User

Untitled

a guest
Dec 13th, 2019
104
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.25 KB | None | 0 0
  1. groupOne = Array.new
  2. groupTwo = Array.new
  3. puts "What is your last name?"
  4. input = STDIN.gets
  5. input.chop!
  6.  
  7. if input ~= /*[a-1]/
  8.     puts "You're in group 1."
  9.     groupOne.push(input)
  10. else
  11.     puts "You're in group 2."
  12.     groupTwo.push(input)
  13. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement