随笔分类 - c++语法知识
各类c++语法知识
摘要:PIMPL(Pointer to Implementation)本质上也属于设计模式的一种,PIMPL也称为 Opaque Pointer(不透明的指针)。主要目的是将一个类的 实现细节(private/protected 方法、成员) 和 其对外的公共接口 分离出来,使得 实现细节 可以在不影响客
阅读全文
摘要:红黑树 1 红黑树的引入 有了二叉搜索树,为什么还需要平衡二叉树? 二叉搜索树容易退化成一条链, 这个时候查找时间复杂度从 \(O(log_2N)\) 退化成 \(O(N)\) 引入对左右子树高度差有限制的平衡二叉树,保证查找操作的最坏时间复杂度也为 \(O(log_2N)\) 有了平衡二叉树,为什
阅读全文
摘要:Why I write First of all, write down the whole process of how I encountered these problems when I learned how to overload the function call operator,
阅读全文
摘要:Why I write First of all, write down the whole process of how I encountered these problems when I learned how to overload the function call operator,
阅读全文

浙公网安备 33010602011771号