Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/arnauddri/algorithms
/ Insert
Method
Insert
data-structures/priority-queue/priority_queue.go:44–46 ·
view source on GitHub ↗
(el Item)
Source
from the content-addressed store, hash-verified
42
}
43
44
func
(pq *PQ) Insert(el Item) {
45
pq.data.Insert(heap.Item(el))
46
}
47
48
func
(pq *PQ) Extract() (el Item) {
49
return
pq.data.Extract().(Item)
Callers
4
ChangePriority
Method · 0.45
TestMaxPriorityQueue
Function · 0.45
TestMinPriorityQueue
Function · 0.45
TestChangePriority
Function · 0.45
Calls
no outgoing calls
Tested by
3
TestMaxPriorityQueue
Function · 0.36
TestMinPriorityQueue
Function · 0.36
TestChangePriority
Function · 0.36