Go: package main

import (
	"bufio"
	"os"
	"strings"
	"strconv"
	"sort"
	"fmt"
)

var scanner = bufio.NewScanner(os.Stdin)

func main() {
	for scanner.Scan() {
		input := strings.Split(scanner.Text(), ",")
		cards := make([]int, 5)
		for i :=range input {
			cards[i], _ = strconv.Atoi(input[i])
		}
		sort.Sort(sort.IntSlice(cards))
		if cards[0] == cards[1] && cards[2] == cards[3] && cards[2] == cards[1] {
			fmt.Println("four card")
		} else if cards[1] == cards[2] && cards[3] == cards[4] && cards[3] == cards[2]{
			fmt.Println("four card")
		} else if cards[0] == cards[1] && cards[1] == cards[2] && cards[3] == cards[4] {
			fmt.Println("full house")
		} else if cards[0] == cards[1] && cards[2] == cards[3] && cards[3] == cards[4] {
			fmt.Println("full house")
		} else if cards[0] == 1 && cards[1] == 10 && cards[2] == 11 && cards[3] == 12 && cards[4] == 13 {
			fmt.Println("straight")
		} else if cards[0]+1 == cards[1] && cards[1]+1 == cards[2] && cards[2]+1 == cards[3] && cards[3]+1 == cards[4] {
			fmt.Println("straight")
		} else if (cards[0] == cards[1] && cards[1] == cards[2]) || (cards[1] == cards[2] && cards[2] == cards[3]) || (cards[2] == cards[3] && cards[3] == cards[4]) {
			fmt.Println("three card")
		} else if ((cards[0] == cards[1]) && ((cards[2] == cards[3]) || (cards[3] == cards[4]))) || ((cards[1] == cards[2]) && (cards[3] == cards[4])) {
			fmt.Println("two pair")
		} else if cards[0] == cards[1] || cards[1] == cards[2] || cards[2] == cards[3] || cards[3] == cards[4] {
			fmt.Println("one pair")
		} else {
			fmt.Println("null")
		}
	}
}

Python: while True:
    try:
        cards = list(map(int, input().split(',')))
        cards.sort()

        if len(set(cards)) == 5:
            c = cards[0]
            if cards == [c, c+1, c+2, c+3, c+4]:
                print("straight")
            elif cards == [1,10,11,12,13]:
                print("straight")
            else:
                print("null")
        else:
            if len(set(cards)) == 2:
                t = cards.count(cards[0])
                if t == 1 or t == 4:
                    print("four card")
                else:
                    print("full house")
            elif len(set(cards)) == 3:
                flag = True
                i = 0
                while flag:
                    c = cards[i]
                    if cards.count(c) == 3:
                        print("three card")
                        flag = False
                    if cards.count(c) == 2:
                        print("two pair")
                        flag = False
                    i += 1
            else:
                print("one pair")
    except:
        break

Python: def hand(card):
    m = 0
    n = [0]*13
    val = 0
    for i in range(13):
        n[i] = card.count(str(i+1))
    for i in range(13):
        if n[i] == 4:
            return 'four card'
    for i in range(13):
        if n[i] == 3:
            for j in range(13):
                if n[j] == 2:
                    return 'full house'
            return 'three card'

    for i in range(13):
        if n[i] == 2:
            for j in range(i+1,13):
                if n[j] == 2:
                    return 'two pair'
            return 'one pair'
    for i in range(len(card)):
        card[i] = int(card[i])
    card.sort()
    
    if card == [1,10,11,12,13]:
        return 'straight'
    for i in range(4):
        if card[4-i] - card[4-i-1] != 1:
            return 'null'
    return 'straight'

while True:
    try:
        card = input().split(',')
        print(hand(card))
            
    except:
        break

Python: straight = [[i for i in range(j,j + 5)] for j in range(1,10)]
straight.append([1,10,11,12,13])
while True:
    try:
        h = list(map(int, input().split(",")))
        h_s = sorted(h)
        p = []
        for i in range(4):
            if h_s[i] != h_s[i + 1]:
                p.append(i)
        if len(p) == 1:
            if p[0] == 0 or p[0] == 3:
                print("four card")
            else:
                print("full house")
        elif h_s in straight:
            print("straight")
        elif len(p) == 2:
            if p[0] == 1 or p == [0,2]:
                print("two pair")
            else:
                print("three card")
        elif len(p) == 3:
            print("one pair")
        else:
            print("null")
    except:
        break

Python: def function(a,b,c,d,e):
	A=[a,b,c,d,e]
	A.sort()
	print(A)
	#4card
	if A[0]==A[3] or A[1]==A[4]:
		print("four card")
	#Full house
	elif (A[0]==A[1] and A[2]==A[4]) or (A[0]==A[2] and A[3]==A[4]):
		print("full house")
	#three card
	elif A[0]==A[2] or A[1]==A[3] or A[2]==A[4]:
		print("three card")
	elif (A[0]==A[1] and A[2]==A[3]) or (A[0]==A[1] and A[3]==A[4]) or (A[1]==A[2] and A[3]==A[4]):
		print("two pair")
	elif A[0]==A[1] or A[1]==A[2] or A[2]==A[3] or A[3]==A[4]:
		print("one pair")
	#straight A?????????
	elif A==[1,10,11,12,13]:
		print("straight")
	#straight A???????????????
	elif A[0]==A[1]-1==A[2]-2==A[3]-3==A[4]-4:
		print("straight")
	else:
		print("null")

while True:
	try:
		a,b,c,d,e=map(int,input().split(','))
		function(a,b,c,d,e)
	except EOFError:
		break

Python: from collections import Counter
import sys

for t in sys.stdin:
    l=sorted(map(int,t[:-1].split(",")))
    s=False
    p1=Counter(l)
    p2=Counter(p1.values())

    if 3 in p2 and 2 in p2:
        print("full house")
    elif 2 in p2:
        if p2[2]==1:
            print("one pair")
        elif p2[2]==2:
            print("two pair")
    elif 3 in p2:
        print("three card")
    elif 4 in p2:
        print("four card")
    else:
        for i in range(1,10):
            if list(range(i,i+5))==l:
                print("straight")
                s=True
                break
        if [1,10,11,12,13]==i:
            print("straight")
            s=True
        if not s:
            print("null")

Python: def function(a,b,c,d,e):
	A=[a,b,c,d,e]
	A.sort()
	#4card
	if A[0]==A[3] or A[1]==A[4]:
		print("four card")
	#Full house
	elif (A[0]==A[1] and A[2]==A[4]) or (A[0]==A[2] and A[3]==A[4]):
		print("full house")
	#three card
	elif A[0]==A[2] or A[1]==A[3] or A[2]==A[4]:
		print("three card")

	elif (A[0]==A[1] and A[2]==A[3]) or (A[0]==A[1] and A[3]==A[4]) or (A[1]==A[2] and A[3]==A[4]):
		print("two pair")
	elif A[0]==A[1] or A[1]==A[2] or A[2]==A[3] or A[3]==A[4]:
		print("one pair")
	#straight A?????????
	elif A==[1,10,11,12,13]:
		print("straight")
	#straight A???????????????
	elif A[0]==A[1]-1==A[2]-2==A[3]-3==A[4]-4:
		print("straight")
	else:
		print("null")

while True:
	try:
		a,b,c,d,e=map(int,input().split(','))
		function(a,b,c,d,e)
	except EOFError:
		break

Python: def function(a,b,c,d,e):
	A=[a,b,c,d,e]
	A.sort()
	if A[0]==A[3] or A[1]==A[4]:
		print("four card")
	elif (A[0]==A[1] and A[2]==A[4]) or (A[0]==A[2] and A[3]==A[4]):
		print("full house")
	elif A[0]==A[2] or A[1]==A[3] or A[2]==A[4]:
		print("three card")

	elif (A[0]==A[1] and A[2]==A[3]) or (A[0]==A[1] and A[3]==A[4]) or (A[1]==A[2] and A[3]==A[4]):
		print("two pair")
	elif A[0]==A[1] or A[1]==A[2] or A[2]==A[3] or A[3]==A[4]:
		print("one pair")
	elif A==[1,10,11,12,13]:
		print("straight")
	elif A[0]==A[1]-1==A[2]-2==A[3]-3==A[4]-4:
		print("straight")
	else:
		print("null")

while True:
	try:
		a,b,c,d,e=map(int,input().split(','))
		function(a,b,c,d,e)
	except EOFError:
		break