Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/LFYSec/MScan
/ exch
Method
exch
src/test/resources/cha/MaxPQ.java:143–147 ·
view source on GitHub ↗
(int i, int j)
Source
from the content-addressed store, hash-verified
141
}
142
143
private
void
exch(
int
i,
int
j) {
144
int
swap = pq[i];
145
pq[i] = pq[j];
146
pq[j] = swap;
147
}
148
149
// is pq[1..n] a max heap?
150
private
boolean isMaxHeap() {
Callers
3
delMax
Method · 0.95
swim
Method · 0.95
sink
Method · 0.95
Calls
no outgoing calls
Tested by
no test coverage detected