
theorem MOQ8:
  for i be Integer holds (i|^4) mod 8 = 0 or (i|^4) mod 8 = 1
  proof
    let i be Integer;
    A1: i|^(2+2) mod 8 = (i|^2*i|^2) mod 8 by NEWTON:8
    .= ((i|^2 mod 8)*(i|^2 mod 8)) mod 8 by NAT_D:67;
    per cases by MOS8;
    suppose
      i|^2 mod 8 = 0;
      hence thesis by A1;
    end;
    suppose
      i|^2 mod 8 = 1;
      hence thesis by A1;
    end;
    suppose
      i|^2 mod 8 = 4; then
      i|^(2+2) mod 8 = (2*8 + 0) mod 8 by A1
      .= 0;
      hence thesis;
    end;
  end;
