#include <string>
#include <iostream>
#include <map>
#include <cstdio>

using namespace std;

int main(){
	int hand[5];

	while(~scanf("%d", &hand[0])){
		for(int i = 1; i < 5; i++){
			scanf(",%d", &hand[i]);
		}
		int num[17] = {0};

		for(int i = 0; i < 5; i ++){
			if(hand[i] == 1){
				hand[i] += 13;
			}
			num[hand[i]]++;
		}

		int h = 0;
		string s[] = {"null", "one pair", "two pair", "three card", "straight", "full house", "four card"};
		int seq = 0;

		for(int i = 2; i < 17; i++){
			if(num[i] == 2){
				if(h == 3){
					h = 5;
				}else{
					h++;
				}
			}
			else if(num[i] == 3){
				if(h == 1){
					h = 5;
				}else{
					h = 3;
				}
			}
			else if(num[i] == 4){
				h = 6;
			}
			else if(num[i-2]&num[i-1]&num[i]&num[i+1]&num[i+2]){
				h = 4;
			}
		}

		cout << s[h] << endl;
	}

	return 0;
}