fork download
  1. With Ada.Text_IO; Use Ada.Text_IO;
  2. With Ada.Integer_Text_IO; Use Ada.Integer_Text_IO;
  3.  
  4. procedure Program is
  5. procedure Intercambia(A,B: in out Integer);
  6. begin
  7. -- your code goes here
  8.  
  9.  
  10. procedure Intercambia(A,B: in out Integer) is
  11. C: integer;
  12. begin
  13. C := A;
  14. A := B;
  15. B := C;
  16. end Intercambia;
  17.  
  18. function Media(A,B: Float) return Float is
  19. begin
  20. return (A + B) / 2.0;
  21. end Media;
  22.  
  23. end Program;
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
gcc -c -pipe -O2 test.adb
test.adb:10:09: declarations must come before "begin"
test.adb:23:01: statement expected
gnatmake: "test.adb" compilation error
stdout
Standard output is empty