摘要:
实验任务三 #include <iostream> #include <fstream> #include <array> #define N 5 int main() { using namespace std; array<int, N> x {97, 98, 99, 100, 101}; of 阅读全文
摘要:
实验任务4 #pragma once #include<iostream> #include<string> using namespace std; class MachinePets{ public: string nickname ; MachinePets(const string s):n 阅读全文
摘要:
实验任务5 #pragma once #include<iostream> #include<cassert> using namespace std; class vectorInt{ public: vectorInt(int n):size{n} { p=new int[size]; cout 阅读全文
摘要:
任务5 #pragma once #include<iostream> #include<string> #include<iomanip> using namespace std; class Info{ public: Info(string name,string cot,string cty 阅读全文
摘要:
实验任务4 #pragma once #include<iostream> #include<cmath> using namespace std; //定义Complex类 class Complex{ public: Complex(double r=0,double i=0):real{r}, 阅读全文
摘要:
任务2:// Point类 // 相较于教材,在构造函数的写法上,采用了业界更通用的初始化列表方式 #include <iostream> using std::cout; using std::endl; // 定义Point类 class Point { public: Point(int x0 阅读全文