program pb;

{$APPTYPE CONSOLE}

uses
  SysUtils;

const
 Filec='box';
 Filei=Filec+'.in';
 Fileo=Filec+'.out';

type TPoint = record
  X,Y: Integer;
end;

var
  tochki: array[1..6] of TPoint;
  tochki2: array[1..6] of TPoint;
  tmp: integer;
  pairsf: array[1..6] of Boolean;
  i,j,count,buf0,buf1: integer;
  oblom: boolean;

label YESYES, NONO, FINISH;

begin
 Assign(input,Filei); Reset(input);
 Assign(output,Fileo);Rewrite(output);

 count := 1;
 for i := 1 to 6 do
   begin
     pairsf[i] := false;
     read (tochki[i].x, tochki[i].y);
     if tochki[i].x > tochki[i].Y then
       begin
         tmp := tochki[i].x;
         tochki[i].x := tochki[i].y;
         tochki[i].y := tmp;
       end;
   end;

   for i := 1 to 6 do
     begin
       if pairsf[i] then continue;
       pairsf[i] := true;
       oblom := true;
       for j := 1 to 6 do
         begin
           if pairsf[j] then continue;
           if (tochki[i].x = tochki[j].x) and (tochki[i].y = tochki[j].Y) then
             begin
               pairsf[j] := true;
               tochki2[count].x := tochki[i].x;
               tochki2[count].y := tochki[i].y;
               inc (count);
               oblom := false;
               break;
             end;
         end;
       if oblom then break;
     end;
   if oblom then goto NONO;

 if tochki2[1].x = tochki2[2].x then
   begin
     buf0 := tochki2[1].y;
     buf1 := tochki2[2].y;
   end
 else if tochki2[1].X = tochki2[2].Y then
   begin
     buf0  := tochki2[1].y;
     buf1  := tochki2[2].x;
   end
 else if tochki2[1].y = tochki2[2].Y then
   begin
     buf0  := tochki2[1].x;
     buf1  := tochki2[2].x;
   end
 else if tochki2[1].y = tochki2[2].x then
   begin
     buf0  := tochki2[1].x;
     buf1  := tochki2[2].y;
   end
  else goto NONO;


 if buf1 = tochki2[3].x then
   begin
     buf1 := tochki2[3].y;
   end
 else if buf1 = tochki2[3].Y then
   begin
     buf1  := tochki2[3].x;
   end
 else goto NONO;


 if buf1 <> buf0 then goto NONO;


 goto YESYES;

 NONO:
   writeln('IMPOSSIBLE');
   goto finish;

 YESYES:
   writeln('POSSIBLE');

 FINISH:

 Close(input);Close(output);
end.
 