loop do
	t = gets
	if t == nil
		break
	end
	c = t.split(",").map{|i| i.to_i}.sort()
	
	if (c[0] == c[1] or c[3] == c[4]) and c[1] == c[2] and c[2] == c[3]
		puts "four card"
	elsif c[0] == c[1] and c[1]==c[2] and c[3] == c[4]
		puts "full house"
	elsif c[0] == c[1] and c[2]==c[3] and c[3] == c[4]
		puts "full house"
	elsif c[0]+1==c[1] and c[1]+1==c[2] and c[2]+1==c[3] and c[3]+1==c[4]
		puts "straight"
	elsif c[0] == 1 and c[1] == 10 and c[2] == 11 and c[3] == 12 and c[4] == 13
		puts "straight"
	elsif (c[0] == c[1] and c[1] == c[2]) or (c[1] == c[2] and c[2] == c[3]) or (c[2] == c[3] and c[3] == c[4])
		puts "three card"
	elsif c.uniq.size == 3
		puts "two pair"
	elsif c.uniq.size == 4
		puts "one pair"
	else
		puts "null"
	end
end