摘要:参考 1. 深入理解 CPU 的分支预测(Branch Prediction)模型; 2. 001 - 为什么处理一段已排序的数组比处理一段未排序的数组快? 完
阅读全文
摘要:参考 1. C++ 头文件是使用 .h 还是 .hpp; 2. stackoverflow-top-cpp; 3. 【我的C语言学习进阶之旅】什么是.hpp文件? 完
阅读全文
摘要:参考 1. 013 - #include <filename> 和 #include "filename" 的区别是什么; 2. stackoverflow-top-cpp; 完
阅读全文
摘要:参考 1. 010 - static_cast, dynamic_cast, const_cast 和 reinterpret_cast 怎么用; 2. stackoverflow-top-cpp; 完
阅读全文
摘要:参考 1. extern “C”的作用详解; 2. 【C++入门】C和C++混合编程超详细讲解_正在起飞的蜗牛的博客-CSDN博客; 3. C++和C的混合编译_iheal的博客-CSDN博客; 完
阅读全文
摘要:前言 步骤 step1:生成Release版本的可执行文件; step2:将生成的可执行文件复制到一个空白文件夹; step3:以QT5.14.2+MinGW7.3.0-64bit开发环境为例,按照以下路径打开Qt5.14.2(MinGW7.3.0 64bit)的命令行界面,运行windeployq
阅读全文
摘要:参考 1. 006 - 关键字 explicit 是什么意思? 2. stackoverflow-top-cpp; 完
阅读全文
摘要:前言 aarch64-linux-gnu-nm freespaceaarch64-linux-nm freespaceaarch64-linux-gnu-nm freespaceaarch64-linux-gnu-objdump -x -s -d freespace addr2line 0x7f92
阅读全文
摘要:前言 code float* lanemap = new float[output_h * output_w]; float* fsmap = new float[output_h * output_w]; cv::Mat showimg; std::vector<PointProp> border
阅读全文
摘要:leetcode_easy_array problem 1475. Final Prices With a Special Discount in a Shop solution #1: 使用新数组更新数据; code solution #2: 直接在原数组更新数据; code: 注意: 1. 满足
阅读全文
摘要:leetcode_easy_array problem 1486. XOR Operation in an Array solution #1: code: 参考 1. leetcode_1486. XOR Operation in an Array; 完
阅读全文
摘要:leetcode_easy_array 1491. Average Salary Excluding the Minimum and Maximum Salary solution #1: code solution #2: code 注意: 1. 去除最大最小值之后的平均值; 2. 数组元素是un
阅读全文
摘要:leetcode_easy_array problem 1480. Running Sum of 1d Array solution #1: code: 参考 1. leetcode_1480. Running Sum of 1d Array; 完
阅读全文
摘要:leetcode_easy_array problem 1470. Shuffle the Array solution #1: code solution #2: code 注意: 1. vector; first, last Input iterators to the initial and
阅读全文
摘要:leetcode_easy_array 1464. Maximum Product of Two Elements in an Array solution #1: code: 参考 1. leetcode_1464. Maximum Product of Two Elements in an Ar
阅读全文
摘要:leetcode_medium_array problem 18. 4Sum solution #1: code 注意: 1. 和3Sum的题目思路基本一致,多了一层循环,使用双指针; 参考 1. leetcode_18. 4Sum; 2. Grandyang; 完
阅读全文
摘要:leetcode_medium_array problem 16. 3Sum Closest solution #1: 三重循环; code: solution #2: 排序后通过双指针移动确定; code 参考 1. leetcode_16. 3Sum Closest; 完
阅读全文
摘要:leetcode_medium_array problem 11. Container With Most Water solution #1: code 参考 1. leetcode_11. Container With Most Water; 完
阅读全文
摘要:leetcode_medium_array problem 15. 3Sum 注意: 1. 题目要求的没有重复的三元组,是指三元组是不同的,但是三元组的元素是可能有相同的; 2. 参考 1. leetcode_15. 3Sum; 2. Grandyang; 完
阅读全文