-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathqueue_main.c
More file actions
33 lines (24 loc) · 745 Bytes
/
queue_main.c
File metadata and controls
33 lines (24 loc) · 745 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/*-------------------------------------------------------------------
Author: Aaron Anthony Valoroso
Date: November 3rd, 2019
License: None
Email: Aaron.A.Valoroso@erdc.dren.mil
To Run (Type): make
--------------------------------------------------------------------*/
#include "queue.h"
int main() {
queue * q = create_queue();
queue * q2 = create_queue();
int i = 0, length = 5;
for(i = 0; i < length; ++i)
push(q, i * 10);
for(i = 0; i < length; ++i)
push(q2, i * 20);
for(i = 0; i < length; ++i)
printf("Looking at: %d\n", pop(q));
for(i = 0; i < length; ++i)
printf("Looking at2: %d\n", pop(q));
queue_cleanup(q);
queue_cleanup(q2);
return 0;
}