Commit 430a56c
committed
feat: add QueueDemo showing FIFO operations using LinkedList as a Queue
Implemented QueueDemo.java to demonstrate enqueue, dequeue, and peek
operations using LinkedList. Highlights LinkedList’s dual behavior as
List and Queue, explaining FIFO processing, complexity, and real-world use cases.
Signed-off-by: https://github.com/Someshdiwan <[email protected]>1 parent bbd93f8 commit 430a56c
File tree
1 file changed
+10
-14
lines changed- Section 25 Collections Frameworks/Queue Interface/src
1 file changed
+10
-14
lines changedLines changed: 10 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | | - | |
4 | | - | |
5 | | - | |
6 | | - | |
7 | | - | |
8 | | - | |
9 | | - | |
10 | | - | |
11 | | - | |
12 | | - | |
13 | 3 | | |
14 | 4 | | |
15 | | - | |
| 5 | + | |
16 | 6 | | |
17 | | - | |
18 | 7 | | |
19 | 8 | | |
20 | 9 | | |
| |||
48 | 37 | | |
49 | 38 | | |
50 | 39 | | |
51 | | - | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
52 | 45 | | |
53 | | - | |
54 | 46 | | |
55 | 47 | | |
56 | 48 | | |
| |||
80 | 72 | | |
81 | 73 | | |
82 | 74 | | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
83 | 79 | | |
0 commit comments