#include <stdio.h>
#include <stdlib.h>

int cmp(const void *a, const void *b){
	return *(int*)a - *(int*)b;
}

int getpair(const int *cards, int n){
	int flag = 0;
	if(n>=2 && cards[0] == cards[1]){
		flag = 0x1;
		if(n>=3 && cards[1] == cards[2]){
			flag = 0x100;
			if(n>=4 && cards[2] == cards[3]){
				flag = 0x1000;
			}else if(n==5 && getpair(cards+3, 2) == 0x1){
				flag = 0x101;
			}
		}else if(n==5 && getpair(cards+2, 3) == 0x100){
			flag = 0x101;
		}else if((n>=4 && getpair(cards+2, 2)) ||
			(n==5 && getpair(cards+3, 2))){
			flag = 0x10;
		}
	}
	return flag;
}

int main(void){
	int cards[5];
	int flag = 0;
	for(int i=0;i<5;++i){
		cards[i] = 0;
	}

	while(scanf("%d,%d,%d,%d,%d",
		cards, cards+1, cards+2, cards+3, cards+4) != EOF){
		qsort(cards, 5, sizeof(int), cmp);
		if(cards[0] + 1 == cards[1] &&
			cards[1] + 1 == cards[2] &&
			cards[2] + 1 == cards[3] &&
			cards[3] + 1 == cards[4]){
			puts("straight");
			continue;
		}else 
		if(cards[0] == 1 && cards[1] == 10 && cards[2] == 11 &&
			cards[3] == 12 && cards[4] == 13){
			puts("straight");
			continue;
		}
		for(int i=0; i<4; ++i){
			flag = getpair(cards+i, 5-i);
			if(flag > 0){ break; }
		}

		switch(flag){
		case 0x1000:
			puts("four card");
			break;
		case 0x101:
			puts("full house");
			break;
		case 0x100:
			puts("three card");
			break;
		case 0x10:
			puts("two pair");
			break;
		case 0x1:
			puts("one pair");
			break;
		case 0x0:
			puts("null");
			break;
		default:
			break;
		}
	}
	return 0;
}