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

  d = b.clone.sort
  d.delete_if { |c| c == 0 }
  h = 'null'

  if s =~ /1{5}/ || s =~ /10{8}1{4}/
    h = 'straight'
  elsif d == [1, 4] then 
    h = 'four card'
  elsif d == [2, 3]
    h = 'full house'
  elsif d == [1, 1, 3]
    h = 'three card'
  elsif d == [1, 2, 2]
    h = 'two pair'
  elsif d == [1, 1, 1, 2]
    h = 'one pair'
  end 

  puts h
end