Data Structured59_q2_heap_find
Heap Find
2b247b7d-1996-4d79-8429-8c2730e89f7f.cppC++
1// Loading code...Selected Submission
0 / 100
0.021s
1648 KB
HeapArray
Time Comp.
O(n) in the worst case for find and find_level, where n is the size of the priority queue.
Space Comp.
O(1)
Readability
6/10
"The code implements a priority queue using an array as the underlying data structure. The `find` and `find_level` functions operate on this array to search for elements and determine their level within the heap structure."
History
| Attempt | Points | Time ↓ |
|---|---|---|
| Try #4 | 0 | 11/1/2024 |
| Try #3 | 100 | 11/1/2024 |
| Try #2 | 100 | 11/1/2024 |
| Try #1 | 100 | 11/1/2024 |