摘要:
BinaryHeap.h文件#ifndef BINARY_HEAP_H#define BINARY_HEAP_Hnamespace ghost{template<typename A>void MinHeapShiftUp(A& array, const size_t size, size_t n/*umber(not index)*/){ if (0 == size) { // array为空 return; } if (size < n || 2 > n) { // n超出有效区间,或者没有父节点 ret...
阅读全文