reserve X,Y for set, p,x,x1,x2,y,y1,y2,z,z1,z2 for object;
reserve f,g,h for Function;

theorem
  {[x1,y1],[x2,y2]} is Function iff (x1 = x2 implies y1 = y2)
proof
  thus {[x1,y1],[x2,y2]} is Function & x1 = x2 implies y1 = y2
  proof
A1: [x1,y1] in {[x1,y1],[x2,y2]} & [x2,y2] in {[x1,y1],[x2,y2]}
     by TARSKI:def 2;
    assume {[x1,y1],[x2,y2]} is Function;
    hence thesis by A1,FUNCT_1:def 1;
  end;
  assume
A2: x1 = x2 implies y1 = y2;
  now
    thus p in {[x1,y1],[x2,y2]} implies ex x,y st [x,y] = p
    proof
      assume p in {[x1,y1],[x2,y2]};
      then p = [x1,y1] or p = [x2,y2] by TARSKI:def 2;
      hence thesis;
    end;
    let x,z1,z2;
A3: [x,z1] = [x1,y1] & [x,z2] = [x1,y1] or [x,z1] = [x2,y2] & [x,z2] = [
    x2,y2] implies z1 = y1 & z2 = y1 or z1 = y2 & z2 = y2 by XTUPLE_0:1;
A4: now
      assume
A5:   [x,z1] = [x1,y1] & [x,z2] = [x2,y2] or [x,z1] = [x2,y2] & [x,z2
      ] = [x1,y1];
      then x = x1 & x = x2 by XTUPLE_0:1;
      hence z1 = z2 by A2,A5,XTUPLE_0:1;
    end;
    assume [x,z1] in {[x1,y1],[x2,y2]} & [x,z2] in {[x1,y1],[x2,y2]};
    hence z1 = z2 by A3,A4,TARSKI:def 2;
  end;
  hence thesis by FUNCT_1:def 1;
end;
