摘要: 任务1 Complex.hpp 1 #pragma once 2 3 #include <iostream> 4 #include <stdexcept> 5 6 // 声明 7 //////////////////////////////////////////////////// 8 // 复数 阅读全文
posted @ 2024-12-16 21:49 芮欣婷 阅读(17) 评论(0) 推荐(0)
摘要: 任务一 publisher.hpp 1 #pragma once 2 3 #include <iostream> 4 #include <string> 5 6 using std::cout; 7 using std::endl; 8 using std::string; 9 10 // 发行/出 阅读全文
posted @ 2024-12-09 09:16 芮欣婷 阅读(6) 评论(0) 推荐(0)
摘要: 任务1: task1_1.cpp: 1 #include <iostream> 2 3 using std::cout; 4 using std::endl; 5 6 // 类A的定义 7 class A { 8 public: 9 A(int x0, int y0); 10 void displa 阅读全文
posted @ 2024-11-25 09:24 芮欣婷 阅读(7) 评论(0) 推荐(0)
摘要: 任务1 button.hpp 1 #pragma once 2 3 #include <iostream> 4 #include <string> 5 6 using std::string; 7 using std::cout; 8 9 // 按钮类 10 class Button { 11 pu 阅读全文
posted @ 2024-11-11 15:54 芮欣婷 阅读(9) 评论(0) 推荐(0)
摘要: 任务1: task1.cpp 1 // 现代C++标准库、算法库体验 2 // 本例用到以下内容: 3 // 1. 字符串string, 动态数组容器类vector、迭代器 4 // 2. 算法库:反转元素次序、旋转元素 5 // 3. 函数模板、const引用作为形参 6 7 #include < 阅读全文
posted @ 2024-10-10 11:49 芮欣婷 阅读(29) 评论(0) 推荐(0)