reserve x,y,z for object;
reserve n,m,k for Element of NAT;
reserve r for Real;

theorem Th3:
  for n ex m st n = 4*m or n = 4*m+1 or n = 4*m+2 or n = 4*m+3
proof
  let n;
  take n div 4;
  set o = n mod 4;
A1: o = 0 or o = 1 or o = 2 or o = 3
  proof
    o < 3 + 1 by NAT_D:1;
    then
A2: o <= 2 + 1 by NAT_1:13;
    now
      per cases by A2,NAT_1:8;
      suppose
A3:     o <= 2;
        now
          per cases by A3,NAT_1:8;
          suppose
A4:         o <= 1;
            now
              per cases by A4,NAT_1:8;
              suppose
                o <= 0;
                hence thesis by NAT_1:2;
              end;
              suppose
                o = 0 + 1;
                hence thesis;
              end;
            end;
            hence thesis;
          end;
          suppose
            o = 1 + 1;
            hence thesis;
          end;
        end;
        hence thesis;
      end;
      suppose
        o = 2 + 1;
        hence thesis;
      end;
    end;
    hence thesis;
  end;
  n = 4*(n div 4) + (n mod 4) by NAT_D:2;
  hence thesis by A1;
end;
