摘要: PWN初学刷题记录 [SWPUCTF 2021 新生赛]nc签到 比较简单 nc连接 /bin/sh cat flag NSSCTF{c5a6491d-b37c-493a-9b74-c578aef0c431} [SWPUCTF 2021 新生赛]gift_pwn shell无反应 ida查看附件 r 阅读全文
posted @ 2025-10-02 15:47 Civilight~Eterna 阅读(17) 评论(0) 推荐(0)
摘要: 问题来源 假设你有一个循环,把若干元素拼接到一个字符串里,每个元素之间用空格分隔: std::string result; for (auto x : elements) { result += x + " "; } 当循环结束时,result 的最后会多一个空格。 比如 elements = {" 阅读全文
posted @ 2025-09-01 21:48 Civilight~Eterna 阅读(15) 评论(0) 推荐(0)
摘要: 题目 解决 典型的字符串处理问题,关键在于非字母(空格)的处理和大小写字母的处理 头文件中有许多常用函数 代码 #include <string> #include<cctype> std::string alphabet_position(const std::string &text) { st 阅读全文
posted @ 2025-09-01 21:36 Civilight~Eterna 阅读(6) 评论(0) 推荐(0)
摘要: 题目如下 了解立方和公式即可 #include<cmath> class ASum { public: static long long findNb(long long m){ //判断m是否是完全平方数 // if(m == sqrt(m)*sqrt(m)){ // int k = m; // 阅读全文
posted @ 2025-08-28 16:07 Civilight~Eterna 阅读(3) 评论(0) 推荐(0)
摘要: Initialization What?: “Provides initial values at the time of construction” - cppreference.com Direct initialization #include <iostream> int main(){ i 阅读全文
posted @ 2025-08-26 23:31 Civilight~Eterna 阅读(9) 评论(0) 推荐(0)
摘要: include <string> #include <vector> std::string reverse_words(const std::string& str) { std::stringstream ss(str); std::vector<std::string>mp; std::str 阅读全文
posted @ 2025-08-26 16:05 Civilight~Eterna 阅读(4) 评论(0) 推荐(0)
摘要: Windows 与 Linux 格式冲突 今天做cs144lab0发现无法编译项目 # 1. 生成编译配置文件 cmake -S . -B build # 2. 编译项目 cmake --build build 多次查阅资料发现原因: Windows 下的文本文件默认使用 CRLF(\r\n) 换行 阅读全文
posted @ 2025-08-10 14:25 Civilight~Eterna 阅读(47) 评论(0) 推荐(0)
摘要: assignment5 treebook Part 1: Viewing Profiles 分析 就一个要求,编写一个将 User 打印到 std::ostream operator<< 方法,即重载运算符<<(此运算符应在 user.h 中声明为友元函数) 要求的效果 User(name=Alic 阅读全文
posted @ 2025-08-01 18:10 Civilight~Eterna 阅读(12) 评论(1) 推荐(0)
摘要: CS106L Lecture 14: Special Member Functions 主要介绍SMFs 阅读全文
posted @ 2025-08-01 18:07 Civilight~Eterna 阅读(8) 评论(0) 推荐(0)
摘要: 【cpp八股】个人记录,持续更新 八股 阅读全文
posted @ 2025-08-01 11:25 Civilight~Eterna 阅读(10) 评论(0) 推荐(0)