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")
		}
	}
}

C++: #include <iostream>
#include <algorithm>
#include <string>
#include <vector>
using namespace std;

int card[13];
int solve(){
    int m;
    vector<int> n;
    for(int i=0;i<13;i++){
        if(card[i]) n.push_back(card[i]);
    }
    for(int i=0;i<n.size();i++){
        for(int j=1;j<n.size()-i;j++){
            if(n[j-1] < n[j]) swap(n[j-1], n[j]);
        }
    }
    if(n[0] == 4){
        cout << "four card" << endl;
    }else if(n[0] == 3){
        if(n[1] == 2){
            cout << "full house" << endl;
        }else{
            cout << "three card" << endl;
        }
    }else if(n[0] == 2){
        if(n[1] == 2){
            cout << "two pair" << endl;
        }else{
            cout << "one pair" << endl;
        }
    }else{
        bool straight=false;
        for(int i=0;i<13-3;i++){
            if(card[i]&&card[i+1]&&card[i+2]&&card[i+3]&&card[(i+4)%13]){
                cout << "straight" << endl;
                straight=true;
                break;
            }
        }
        if(!straight){
            cout << "null" << endl;
        }
    }
}

int main(){
    char comma;
    int m;
    while(cin >> m){
        for(int i=0;i<13;i++){
            card[i] = 0;
        }
        m--;
        card[m]++;
        for(int i=0;i<4;i++){
            cin >> comma >> m;
            m--;
            card[m]++;
        }
        solve();
    }
}

C++: #include<iostream>
#include<algorithm>

using namespace std;

int main(){

	bool test = false;
	int A[13] = {};
	int a;
	
	while(1) {
	for(int i=0;i<5;i++) {
		
		cin >> a;
		
		A[a-1]++;
	
	}
	if ( A[0] == 1 && A[9] == 1 && A[10] == 1 && A[11] == 1 && A[12] ==1 ) {
	cout << "straight\n";
	continue;
}
	
	for(int i=0;i<9;i++)
	if ( A[i] == 1 && A[i+1] == 1 && A[i+2] == 1 && A[i+3] == 1 && A[i+4] ==1 ) {
	test = true;
	continue;
}
	
	sort(A, A+13);
	
	if(test)
	cout << "straight\n";
	
	else if( A[11] == 1 && A[12] == 2)
	cout << "one pair\n";
	
	else if( A[11] == 2 && A[12] == 2)
	cout << "two pair\n";
	
	else if( A[11] == 1 && A[12] == 3 )
	cout << "three card\n";
	
	else if( A[11] == 2 && A[12] == 3)
	cout << "full house\n";
	
	else if( A[12] == 4)
	cout << "four card\n";
	
	else 
	cout << "null\n";
	for(int i=0;i<13;i++)
	A[i] = 0;
}
    return 0;
}

C++: #include<bits/stdc++.h>
#define EPS (1e-10)
#define rep(i,n)for(int i=0;i<n;i++)
using namespace std;

int main() {
	int a[5];
	while (~scanf("%d,%d,%d,%d,%d", &a[0], &a[1], &a[2], &a[3], &a[4])) {
		sort(a, a + 5);
		if ((a[0] == a[1] && a[0] == a[2] && a[0] == a[3]) || (a[1] == a[2] && a[1] == a[3] && a[1] == a[4]))puts("four card");
		else if ((a[0] == a[1] && a[0] == a[2] && a[3] == a[4]) || (a[0] == a[1] && a[2] == a[3] && a[2] == a[4]))puts("full house");
		else if ((a[1] == a[0] + 1 && a[2] == a[1] + 1 && a[3] == a[2] + 1 && a[4] == a[3] + 1) || (a[0] == 1 && a[1] == 10 && a[2] == 11 && a[3] == 12 && a[4] == 13))puts("straight");
		else if ((a[0] == a[1] && a[0] == a[2]) || (a[1] == a[2] && a[1] == a[3]) || (a[2] == a[3] && a[2] == a[4]))puts("three card");
		else if ((a[0] == a[1] && a[2] == a[3]) || (a[0] == a[1] && a[3] == a[4]) || (a[1] == a[2] && a[3] == a[4]))puts("two pair");
		else if (a[0] == a[1] || a[1] == a[2] || a[2] == a[3] || a[3] == a[4])puts("one pair");
		else puts("null");
	}
	return 0;
}

C++: #include <iostream>
#include <stdio.h>
#include <algorithm>
using namespace std;

int main() {
  int c[5] = {0},same[5] = {0};

  while(scanf("%d,%d,%d,%d,%d\n",&c[0],&c[1],&c[2],&c[3],&c[4]) == 5) {
    int same[5] = {0};
    bool straight;
    for(int i=0;i<5;i++) {
      for(int j=0;j<5;j++) {
	if(c[i] == c[j]) {
	  same[i]++;
	}
      }
    }
    sort(c,c+5);
    sort(same,same+5);
    /*    for(int i=0;i<5;i++) {
    cout << same[i] << " " << endl;
    }
    */
    if(same[4] == 4) {
      cout << "four card" << endl;
    }
    else if(same[4] == 3) {
      if(same[3] == 2) {
	cout << "full house" << endl;
      }
      else {
	cout << "three card" << endl;
      }
    }
    else if(same[4] == 2) {
      if((same[3] == 2) &&(same[2] == 2)) {
	cout << "two pair" << endl;
      }
      else {
	cout << "one pair" << endl;
      }
    }
    else if(same[4] == 1) {
      for(int i=0;i<4;i++) {
	if(c[i] == c[i+1]-1) {
	  straight = true;
	}
	else {
	  straight == false;
	  break;
	}
      }
      if(straight) {
	cout << "straight" << endl;
      }
      else {
	cout << "null" << endl;
      }
    }

  }
}