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