This commit is contained in:
2025-09-15 21:12:04 +08:00
commit 3f58f483ff
144 changed files with 5298 additions and 0 deletions

23
dataStruct/Heap/Heap.h Normal file
View File

@@ -0,0 +1,23 @@
//
// Created by 李洋 on 2023/8/12.
//
#ifndef LEECODE_C_HEAP_H
#define LEECODE_C_HEAP_H
#include "vector"
template<typename T>
class Heap {
private:
std::vector<T> array;
public:
int length;
Heap(std::vector<T> &array) : array(array){
length = array.size();
}
typedef void (Heap::*compare(T a,T b))(bool);
};
#endif //LEECODE_C_HEAP_H