#include <iostream>
#include <map>

using namespace std;

void solve()
{
	int a[5];
	while(~scanf("%d,%d,%d,%d,%d", &a[0], &a[1], &a[2], &a[3], &a[4], &a[5]))
	{
		map<int, int> Map;
		for(int i = 0; i < 5; ++i)
		{
			++Map[a[i]];
		}
		if(Map.size() == 2)
		{
			int Max = 0;
			for(map<int, int>::iterator Ite = Map.begin(); Ite != Map.end(); ++Ite)
			{
				if(Max < Ite->second)
				{
					Max = Ite->second;
				}
			}
			if(Max == 3)
			{
				cout << "full house" << endl;
			}
			else
			{
				cout << "four card" << endl;
			}
		}
		else if(Map.size() == 3)
		{
			int Max = 0;
			for(map<int, int>::iterator Ite = Map.begin(); Ite != Map.end(); ++Ite)
			{
				if(Max < Ite->second)
				{
					Max = Ite->second;
				}
			}
			if(Max == 3)
			{
				cout << "three card" << endl;
			}
			else
			{
				cout << "two pair" << endl;
			}
		}
		else if(Map.size() == 4)
		{
			cout << "one pair" << endl;
		}
		else
		{
			map<int, int>::iterator Ite = Map.begin();
			map<int, int>::iterator IteNext = Map.begin();
			++IteNext;
			map<int, int>::iterator IteEnd = Map.end();
			IteEnd--;
			if(IteEnd->first - Ite->first == 4 || IteNext->first - Ite->first == 9)
			{
				cout << "straight" << endl;
			}
			else
			{
				cout << "null" << endl;
			}
		}
	}
}

int main()
{
	solve();
	return(0);
}
#define	_USE_MATH_DEFINES
#include <iostream>
#include <algorithm>
#include <functional>
#include <vector>
#include <cstdio>
#include <cstring>
#include <cmath>
#include <cfloat>
#include <map>
#include <queue>
#include <stack>
#include <list>
#include <string>
using namespace std;
char shima[13][13];
void tansaku(int x,int y){
	if(x<0||x>11||y<0||y>11||shima[y][x]=='0')
		return ;
	if(shima[y][x]=='1'){
		shima[y][x]='0';
	}
	tansaku(x+1,y);
	tansaku(x-1,y);
	tansaku(x,y+1);
	tansaku(x,y-1);
	
}
int main(){
	
	while(cin>>shima[0][0]){
	for(int i=0;i<12;i++){
		for(int j=0;j<12;j++){
			if(i==0&&j==0)
			continue;
			else
			cin>>shima[i][j];
		}
	}
		int a=0;
		for(int i=0;i<12;i++){
			for(int j=0;j<12;j++){
				if(shima[i][j]=='1'){
					tansaku(j,i);
					a++;
				}
			}
		}
		cout<<a<<endl;
	}
}

	