@@ -86,6 +86,17 @@ This page contains the complexities of different algorithms in this repository.
86
86
* C++
87
87
* [ MISC STACKS] ( #misc-stacks )
88
88
* QUEUES
89
+ * SIMPLE QUEUE
90
+ * FIXED ARRAY SIMPLE QUEUE
91
+ * DYNAMIC ARRAY SIMPLE QUEUE
92
+ * LINKED SIMPLE QUEUE
93
+ * CIRCULAR QUEUE
94
+ * FIXED ARRAY CIRCULAR QUEUE
95
+ * LINKED CIRCULAR QUEUE
96
+ * PRIORITY QUEUE
97
+ * FIXED ARRAY PRIORITY QUEUE
98
+ * LINKED PRIORITY QUEUE
99
+ * HEAPED PRIORITY QUEUE
89
100
* HASHTABLE
90
101
* TREES
91
102
* HEAPS
@@ -386,6 +397,68 @@ SNo. | Operations | Order and Type of Time Complexity O(n) | Order and Type of S
386
397
387
398
### QUEUES
388
399
400
+ #### SIMPLE QUEUE
401
+
402
+ ##### FIXED ARRAY SIMPLE QUEUE
403
+
404
+ SNo. | Operations | Order and Type of Time Complexity O(n) | Order and Type of Space Complexity
405
+ ---- | ---------- | -------------------------------------- | ----------------------------------
406
+ 1 | Enqueue an element or Insert element | O(1) -- Constant | O(1) -- Constant
407
+ 2 | Dequeue an element or Delete element | O(1) -- Constant | O(1) -- Constant
408
+ 3 | Print the queue | O(n) -- Linear | O(1) -- Constant
409
+ 4 | Size of the queue | O(1) -- Constant | O(1) -- Constant
410
+ 5 | Queue is Empty or not | O(1) -- Constant | O(1) -- Constant
411
+
412
+ ##### DYNAMIC ARRAY SIMPLE QUEUE
413
+
414
+ SNo. | Operations | Order and Type of Time Complexity O(n) | Order and Type of Space Complexity
415
+ ---- | ---------- | -------------------------------------- | ----------------------------------
416
+ 1 | Enqueue an element or Insert element | O(1) -- Constant | O(log n) -- Logarthmic
417
+ 2 | Dequeue an element or Delete element | O(1) -- Constant | O(1) -- Constant
418
+ 3 | Print the queue | O(n) -- Linear | O(1) -- Constant
419
+ 4 | Size of the queue | O(1) -- Constant | O(1) -- Constant
420
+ 5 | Queue is Empty or not | O(1) -- Constant | O(1) -- Constant
421
+
422
+ ##### LINKED SIMPLE QUEUE
423
+
424
+ SNo. | Operations | Order and Type of Time Complexity O(n) | Order and Type of Space Complexity
425
+ ---- | ---------- | -------------------------------------- | ----------------------------------
426
+ 1 | Enqueue an element or Insert element | O(n) -- Linear | O(1) -- Constant
427
+ 2 | Dequeue an element or Delete element | O(1) -- Constant | O(1) -- Constant
428
+ 3 | Print the queue | O(n) -- Linear | O(1) -- Constant
429
+ 4 | Size of the queue | O(1) -- Constant | O(1) -- Constant
430
+ 5 | Queue is Empty or not | O(1) -- Constant | O(1) -- Constant
431
+
432
+ #### CIRCULAR QUEUE
433
+
434
+ ##### FIXED ARRAY CIRCULAR QUEUE
435
+
436
+ SNo. | Operations | Order and Type of Time Complexity O(n) | Order and Type of Space Complexity
437
+ ---- | ---------- | -------------------------------------- | ----------------------------------
438
+ 1 | Enqueue an element or Insert element | O(1) -- Constant | O(1) -- Constant
439
+ 2 | Dequeue an element or Delete element | O(1) -- Constant | O(1) -- Constant
440
+ 3 | Print the queue | O(n) -- Linear | O(1) -- Constant
441
+ 4 | Size of the queue | O(1) -- Constant | O(1) -- Constant
442
+ 5 | Queue is Empty or not | O(1) -- Constant | O(1) -- Constant
443
+
444
+ ##### LINKED CIRCULAR QUEUE
445
+
446
+ #### PRIORITY QUEUE
447
+
448
+ ##### FIXED ARRAY PRIORITY QUEUE
449
+
450
+ ##### LINKED PRIORITY QUEUE
451
+
452
+ SNo. | Operations | Order and Type of Time Complexity O(n) | Order and Type of Space Complexity
453
+ ---- | ---------- | -------------------------------------- | ----------------------------------
454
+ 1 | Insert element with priority | O(n) -- Linear | O(1) -- Constant
455
+ 2 | Delete element with highest priority | O(1) -- Constant | O(1) -- Constant
456
+ 3 | Print the queue | O(n) -- Linear | O(1) -- Constant
457
+ 4 | Size of the queue | O(1) -- Constant | O(1) -- Constant
458
+ 5 | Queue is Empty or not | O(1) -- Constant | O(1) -- Constant
459
+
460
+ ##### HEAPED PRIORITY QUEUE
461
+
389
462
### HASHTABLE
390
463
391
464
### TREES
0 commit comments