$<.map{|i|a=i.chop.split(?,).map(&:to_i).sort;b=a.uniq.map{|j|a.count(j)}.sort.reverse;s=b.size;puts b[0]>3?"four card":b[0]>2?s>2?"three card":"full house":b[0]>1?s>3?"one pair":"two pair":a[4]-a[0]<5||a[1]>9?:strait: :null}