上一页 1 ··· 28 29 30 31 32 33 34 35 36 ··· 66 下一页
摘要: title: C++ std::set通过另一个类型查询 date: 2022-10-04 14:44:21 tags: 在Comparator里加上typedef std::true_type is_transparent;。原因主要是为了保持前向兼容。 #include <cassert> #i 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(1) 评论(0) 推荐(0) 编辑
摘要: title: C++ backports date: 2023-07-17 16:52:29 tags: std::optional (since C++17) #include <iostream> struct in_place_t {}; inline constexpr in_place_t 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(0) 评论(0) 推荐(0) 编辑
摘要: title: C++ Debug笔记——在库和main中使用相同的类名引发的惨案 date: 2023-08-03 21:16:54 tags: 背景 程序A 动态链接 库B,库B中有一个内部使用的Timers类,程序A中也有一个内部使用的Timers,两者都没有被置于namespace中。 现象 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(0) 评论(0) 推荐(0) 编辑
摘要: title: "Clang 'constexpr' specifier is incompatible with C++98 [Semantic Issue]" date: 2020-05-01 21:22:54 tags: 参考: https://github.com/jbenden/vscode 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(1) 评论(0) 推荐(0) 编辑
摘要: title: C++获取日期时间戳 date: 2020-04-30 12:23:41 tags: 使用C++11里的std::chrono,自定义一个叫做days的duration。 #include <iostream> #include <chrono> typedef std::chrono 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(4) 评论(0) 推荐(0) 编辑
摘要: title: C++生成随机数 date: 2020-05-04 21:50:19 tags: 大段随机二进制 思路:先用std::random_device生成真随机数,用来初始化长周期随机数发生器std::mt19937,然后再用std::mt19937来不断生成随机数。 生成大段随机二进制的部 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(1) 评论(0) 推荐(0) 编辑
摘要: title: C++找出多个数的最大值 date: 2020-05-01 15:00:46 tags: 参考:https://codereview.stackexchange.com/questions/26100/maximum-of-three-values-in-c 找出多个变量的最大值 使用 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(1) 评论(0) 推荐(0) 编辑
摘要: title: C++库函数manual date: 2020-07-05 13:03:47 tags: 在线 sudo apt install -y cppman cppman next_permutation 离线 git clone git@github.com:jeaye/stdman.git 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(0) 评论(0) 推荐(0) 编辑
摘要: title: C++宏定义学习笔记 date: 2019-07-14 18:39:46 tags: 学习笔记 参考:https://blog.csdn.net/shuzfan/article/details/52860664 基本语法 #if CONDITION1 ... #elif CONDITI 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(6) 评论(0) 推荐(0) 编辑
摘要: title: C++学习笔记 date: 2020-04-03 23:33:34 .clang-format # <https://clang.llvm.org/docs/ClangFormatStyleOptions.html> IndentWidth: 4 UseTab: Always TabW 阅读全文
posted @ 2024-09-28 14:05 寻找繁星 阅读(0) 评论(0) 推荐(0) 编辑
上一页 1 ··· 28 29 30 31 32 33 34 35 36 ··· 66 下一页