会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
xu2993610
博客园
首页
新随笔
联系
订阅
管理
2022年11月30日
实验6 模板类和文件I/O
摘要: 1. 程序源码 task1 #include <iostream> #include <fstream> #include "Complex.hpp" void test1() { using namespace std; Complex<double> c1{1, 2}, c2; cout <<
阅读全文
posted @ 2022-11-30 19:00 阑夜风华
阅读(75)
评论(0)
推荐(0)
2022年11月25日
实验5 继承和多态
摘要: 1.实验任务1 task1_1 程序源码 #include <iostream> #include <map> #include <string> int main() { using namespace std; map<int, string> grade_dict{{5, "Excellent
阅读全文
posted @ 2022-11-25 14:58 阑夜风华
阅读(37)
评论(0)
推荐(0)
2022年11月2日
实验4 类与数组、指针
摘要: 实验任务1 程序源码 point.hpp #pragma once #include <iostream> using std::cout; using std::endl; class Point { public: Point(): x{0}, y{0} {} Point(int x0, int
阅读全文
posted @ 2022-11-02 19:02 阑夜风华
阅读(45)
评论(0)
推荐(0)
2022年10月21日
实验3 数组、指针与现代c++标准库
摘要: 1.实验任务1 程序源码 task1_1 #include <iostream> using std::cout; using std::endl; class A{ public: A(int x0, int y0): x{ x0 }, y{ y0 } {} void show() const {
阅读全文
posted @ 2022-10-21 14:46 阑夜风华
阅读(52)
评论(0)
推荐(0)
2022年10月14日
实验2 类和对象(2)
摘要: 实验任务1 程序源码 #include <iostream> #include <complex> int main(){ using namespace std; complex<double> c1{3, 4}, c2{4.5}; const complex<double> c3{c2}; co
阅读全文
posted @ 2022-10-14 14:37 阑夜风华
阅读(35)
评论(0)
推荐(0)
2022年10月3日
实验1 类和对象(1)
摘要: 1.实验任务1 task1_1 程序源码 #include<iostream> #include<string> #include<vector> int main() { using namespace std; string s1; string s2{"c plus plus"}; strin
阅读全文
posted @ 2022-10-03 18:23 阑夜风华
阅读(27)
评论(0)
推荐(0)
公告