数据结构
ปรัชญา แค้วคำมูล
大道至简, 繁在人心
展开
-
以vector的遍历形式遍历map操作数据误区&&map中的[]运算符原理!
为什么stl对于map要提供operator []运算符重载,并且不存在的key在被索引后被添加到了map中并被赋予了一个默认值?转载 2022-08-22 17:43:12 · 242 阅读 · 0 评论 -
c++多叉树基本操作实现
c++多叉树基本操作原创 2021-12-31 11:34:25 · 828 阅读 · 0 评论 -
LCP 09. 最小跳跃次数——优化、打印路径(BD二面算法)
LCP 09. 最小跳跃次数(BD二面算法)原创 2021-12-15 09:34:31 · 294 阅读 · 0 评论 -
LintCode76 求最长上升子序列——思路、优化、打印序列
LintCode76 求最长上升子序列——思路、优化、打印序列原创 2021-12-15 09:31:29 · 237 阅读 · 0 评论 -
内存池——nginx内存池跟stl内存池对比
内存池——nginx内存池跟stl内存池对比原创 2021-09-03 16:16:20 · 227 阅读 · 0 评论 -
LeeCode精选top面试题
1.原创 2020-12-01 11:32:05 · 213 阅读 · 0 评论 -
数据结构图(无向/有向)的邻接链表表示——基本操作c++模板实现
// 图基本操作_邻接表#if 1#include <iostream>#include <vector>using namespace std;#define MAX_SIZE 100// 表节点//template <class InfoData>struct EdgeNode{ //InfoData info; // 边的权值 uint32_t pos; EdgeNode* next;};// 头节点template <.原创 2020-11-18 11:35:22 · 418 阅读 · 0 评论 -
C++模板实现平衡二叉树基本操作
// 平衡二叉树基本操作#if 1#include <iostream>#include <vector>using namespace std;template<class DataType>struct BinTreeNode{ BinTreeNode* left; BinTreeNode* right; DataType data;};template<class DataType>class BinTree{publ.原创 2020-11-12 17:41:00 · 304 阅读 · 0 评论