摘要: 任务一 botton.hpp #pragma once #include <iostream> #include <string> //定义Button类 class Button { public: Button(const std::string& label);//构造函数,以只读,引用的方式 阅读全文
posted @ 2026-11-27 00:06 yyyyy_0617 阅读(13) 评论(0) 推荐(0)
摘要: 任务一 一、源代码 //t.cpp #include "t.hpp" #include <iostream> #include <stdexcept> #include <string> const std::string T::doc{"a simple class sample"}; const 阅读全文
posted @ 2026-11-19 23:59 yyyyy_0617 阅读(6) 评论(0) 推荐(0)
摘要: 任务一 1.源代码 // 现代C++标准库、算法库体验 // 本例用到以下内容: // 1. 字符串string, 动态数组容器类vector、迭代器 // 2. 算法库:反转元素次序、旋转元素 // 3. 函数模板、const引用作为形参 #include <iostream> #include 阅读全文
posted @ 2026-10-17 17:29 yyyyy_0617 阅读(13) 评论(0) 推荐(0)