ex69.pp 304 B

12345678910111213141516
  1. Program Example69;
  2. { Program to demonstrate the Swap function. }
  3. Var W : Word;
  4. L : Longint;
  5. begin
  6. W:=$1234;
  7. W:=Swap(W);
  8. if W<>$3412 then
  9. writeln ('Error when swapping word !');
  10. L:=$12345678;
  11. L:=Swap(L);
  12. if L<>$56781234 then
  13. writeln ('Error when swapping Longint !');
  14. end.