program box;

{$APPTYPE CONSOLE}

uses
  SysUtils;

var f,f1:text;
w:array [1..6,1..4] of integer;
i,j:integer;
r:word;
jas:boolean;
begin
    assign(f,'box.in');
    assign(f1,'box.out');
    reset(f);
    rewrite(f1);
    jas:=true;
    r:=0  ;

    for i:=1 to 6 do
     begin
      read(f,w[i,1],w[i,2]);
     end;
    for i:=1 to 6 do
     if (w[1,1]<>w[i,1]) or (w[1,1]<>w[i,2]) then jas:=false;
    if jas then  writeln(f1,'POSSIBLE') else
 begin
    for i:=1 to 6 do
     for j:=1 to 6 do
     if i<>j then
     begin
      if (w[i,1]=w[j,1]) or (w[i,1]=w[j,2]) then w[i,3]:=w[i,3]+1;
      if (w[i,2]=w[j,1]) or (w[i,2]=w[j,2]) then w[i,4]:=w[i,4]+1;

     end;
     r:=0;
     for i:=1 to 6 do
      if (w[i,3]<>3) or (w[i,4]<>3) then r:=1;
     if r=0 then writeln(f1,'POSSIBLE')
      else
      begin
       r:=0;
       for i:=1 to 6 do
       begin
        if (w[i,3]<>3) and (w[i,4]<>5) then r:=1;
        end;
      if r=0 then  writeln(f1,'POSSIBLE');

      end;

     end;
    close(f);
    close(f1);
  { TODO -oUser -cConsole Main : Insert code here }
end.
