while line = STDIN.gets
  cards = line.chomp.split(',').map { |item| item.to_i }
  cards.sort!
  if (cards[0] == cards[1] and cards[0] == cards[2] and cards[0] == cards[3]) or (cards[1] == cards[2] and cards[1] == cards[3] and cards[1] == cards[4]) then
    puts "four card"
  elsif (cards[0] == cards[1] and cards[0] == cards[2] and cards[3] == cards[4]) or (cards[0] == cards[1] and cards[2] == cards[3] and cards[2] == cards[4]) then   
    puts "full house"
  elsif (cards[0]+1 == cards[1] and cards[0]+2 == cards[2] and cards[0]+3 == cards[3] and cards[0]+4 == cards[4]) or (cards[0] == 1 and cards[1] == 10 and cards[2] == 11 and cards[3] == 12 and cards[4] == 13) then
    puts "straight"
  elsif (cards[0] == cards[1] and cards[0] == cards[2]) or (cards[1] == cards[2] and cards[1] == cards[3]) or (cards[2] == cards[3] and cards[2] == cards[4]) then
    puts "three card"
  elsif (cards[0] == cards[1] and cards[2] == cards[3]) or (cards[1] == cards[2] and cards[3] == cards[4]) or (cards[0] == cards[1] and cards[3] == cards[4]) then
    puts "two pair"
  elsif cards[0] == cards[1] or cards[1] == cards[2] or cards[2] == cards[3] or cards[3] == cards[4] then
    puts "one pair"
  else
    puts "null"
  end
end