while s = gets
  b = Array.new(13, 0)
  s.split(',').each { |c| b[c.to_i - 1] += 1 } 
  s = b.join
  b.delete(0)

  h = 'null'

  case b.sort
    when [1, 1, 1, 1, 1]
      h = 'straight' if s =~ /1{5}/ || s =~ /10{8}1{4}/
    when [1, 4]
      h = 'four card'
    when [2, 3]
      h = 'full house'
    when [1, 1, 3]
      h = 'three card'
    when [1, 2, 2]
      h = 'two pair'
    when [1, 1, 1, 2]
      h = 'one pair'
  end
   
  puts h
end