tasks a-s
This commit is contained in:
parent
47bf37c096
commit
b83f433714
12433 changed files with 156208 additions and 123 deletions
17
Task/Queue-Definition/Ada/queue-definition-3.ada
Normal file
17
Task/Queue-Definition/Ada/queue-definition-3.ada
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
with Fifo;
|
||||
with Ada.Text_Io; use Ada.Text_Io;
|
||||
|
||||
procedure Fifo_Test is
|
||||
package Int_Fifo is new Fifo(Integer);
|
||||
use Int_Fifo;
|
||||
My_Fifo : Fifo_Type;
|
||||
Val : Integer;
|
||||
begin
|
||||
for I in 1..10 loop
|
||||
Push(My_Fifo, I);
|
||||
end loop;
|
||||
while not Is_Empty(My_Fifo) loop
|
||||
Pop(My_Fifo, Val);
|
||||
Put_Line(Integer'Image(Val));
|
||||
end loop;
|
||||
end Fifo_Test;
|
||||
Loading…
Add table
Add a link
Reference in a new issue