Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
29
Task/Queue-Definition/Elisa/queue-definition-2.elisa
Normal file
29
Task/Queue-Definition/Elisa/queue-definition-2.elisa
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
use GenericQueue (QueueofPersons, Person);
|
||||
type Person = text;
|
||||
Q = QueueofPersons(25);
|
||||
|
||||
Push (Q, "Peter");
|
||||
Push (Q, "Alice");
|
||||
Push (Q, "Edward");
|
||||
Q?
|
||||
QueueofPersons:[MaxLength = 25;
|
||||
length = 3;
|
||||
list = { "Peter",
|
||||
"Alice",
|
||||
"Edward"}]
|
||||
Pull (Q)?
|
||||
"Peter"
|
||||
|
||||
Pull (Q)?
|
||||
"Alice"
|
||||
|
||||
Pull (Q)?
|
||||
"Edward"
|
||||
|
||||
Q?
|
||||
QueueofPersons:[MaxLength = 25;
|
||||
length = 0;
|
||||
list = { }]
|
||||
|
||||
Pull (Q)?
|
||||
***** Exception: Queue Underflow
|
||||
Loading…
Add table
Add a link
Reference in a new issue