Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Bc130400116
--GNAT 4.9.3 WITH Ada.Integer_Text_IO; USE Ada.Integer_Text_IO; WITH Ada.Text_IO; USE Ada.Text_IO; PROCEDURE Assignment IS TYPE MyArray IS ARRAY(1..16) OF Integer; PROCEDURE PUT(A: MyArray) IS BEGIN FOR B IN A'RANGE LOOP Put (A(B), Width =>4); END LOOP; New_Line; END Put; A: MyArray := (11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26); C: MyArray := A; BEGIN Put_Line ("Chunks of Source array:"); Put(A); New_Line; Put_Line ("Chunks of Destination array:"); C(1..4) := A(9..12); C(5..8) := A(1..4); C(9..12) := A(13..16); C(13..16) := A(5..8); Put(C); END Assignment;
run
|
edit
|
history
|
help
0
Memory Alignment
division_emtera_p.adb
Dynamic Dispatching
Controlled types (temporary anonymous objects)
Dynamic Dispatching with no dynamic allocation
function calling using pointers
Ada nested lexical scope
ordenar.adb
susuma_dos_enteros.adb
Iterator Interface