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

int cmp( const void *a, const void *b )
{
	int *aa = (int *)a;
	int *bb = (int *)b;

	if( aa[0] != bb[0] )
		return bb[0]-aa[0];

	return (bb[1])-(aa[1]);
}

int main()
{
	int mas[6][2];
	int i,j,tmp;

	freopen("box.in", "rt", stdin);
	freopen("box.out", "wt", stdout);

	for( i = 0; i<6; i++){
		for( j = 0; j<2; j++)
			scanf("%d",&mas[i][j]);
		if( mas[i][0] < mas[i][1] ){
			tmp = mas[i][0];
			mas[i][0] = mas[i][1];
			mas[i][1] = tmp;
		}
	}

	qsort(mas, 6, sizeof(mas[0]), cmp );

	for( i = 0; i<3; i++ ){
		if( ( mas[2*i][0] != mas[2*i+1][0] ) || ( mas[2*i][1] != mas[2*i+1][1] ) ){
			printf("IMPOSSIBLE\n");
			return 0;
		}
	}

	if( mas[0][0] != mas[2][0] ){
		printf("IMPOSSIBLE\n");
		return 0;
	}

	if( mas[0][1] != mas[4][0] ){
		printf("IMPOSSIBLE\n");
		return 0;
	}

	if( mas[2][1] != mas[4][1] ){
		printf("IMPOSSIBLE\n");
		return 0;
	}

	printf("POSSIBLE\n");

	return 0;
}

