- 博客(124)
- 收藏
- 关注
原创 C++伴我成长
光阴似箭,日月如梭,不知不觉大学生活已过去一年。想想去年的今天,还在为报考什么大学什么专业而发愁,而如今学习专业已经成为定局,能为自己做的就是把专业课学好。 初学C++,感觉编程好神奇,看着一串串的代码,对程序员的敬仰之情由然而生。既来之,则安之,硬着头皮上了。看着贺老师布置的任务,看着同学们编出的一个个程序,和半天写不出几行代码的自己,学会了复制粘贴。时间一天天过去,看着同学们的进
2013-07-11 19:55:21 1646 1
原创 旧题再做涨工资
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: fun.cpp* 作 者:隋 鑫* 完成日期:2013 年6月 14日* 版本号: v1.0* 对任务及求解方法的描述部分:类与职工工资* 输入描述:略* 问题描述:略* 程序输出:如下*/#i
2013-06-14 10:57:59 774
原创 编程题
#include using namespace std;class Tast{ public: void init(int a,int b); void print(); private: int x; int y;};void Tast::init(int a,int b) { x=a;
2013-06-04 09:23:38 712
原创 立方体类族
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 6 月 3 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namesp
2013-06-03 19:54:19 783
原创 形状类族
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 6 月 3 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namesp
2013-06-03 18:32:47 767
原创 动物怎么叫
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 6 月 2 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include #include usi
2013-06-02 19:41:50 1058
原创 阅读程序2
#include using namespace std;class Mammal{public: Mammal( ) { cout<<"Mammal constructor called."<<endl; } virtual ~Mammal()//虚析构函数 { cout<<"Mammal destructor ca
2013-05-30 16:15:50 703
原创 阅读程序1
#include using namespace std;class BASE{private: char c;public: BASE(char n):c(n) {} virtual ~BASE() { cout<<c; }};class DERIVED:public BASE{private: char c;p
2013-05-30 16:07:43 743
原创 交通工具类3
#include using namespace std;class Vehicle{public: virtual void run() const = 0; //(3) run()为纯虚函数};class Car: public Vehicle //汽车{public: void run() const { cout << "run a ca
2013-05-30 15:50:33 1257
原创 交通工具2
#include using namespace std;class Vehicle //交通工具{public: virtual void run() const { cout << "run a vehicle. "<<endl; } //(2) run()为虚函数};class Car: public Vehicle //汽车{public
2013-05-30 15:41:02 1014 1
原创 交通工具类1
#include using namespace std;class Vehicle //交通工具{public: void run() const { cout << "run a vehicle. "<<endl; }};class Car: public Vehicle //汽车{public: void run() con
2013-05-30 15:27:20 1332
原创 日期时间类
#includeusing namespace std;class Date{public: void SetDate(int y,int m,int d) { year=y; month=m; day=d; } void PrintDate() { cout<
2013-05-29 19:55:13 735
原创 多重继承派生Teacher_Cader类
#include #includeusing namespace std;class Teacher{public: Teacher(string nam,int a,char s,string tit,string ad,string t) { name=nam; age=a; sex=s; title=tit; addr=ad;
2013-05-29 19:45:25 889
原创 派生类StudentB对基类StudentA的继承
#include #include using namespace std;class StudentA //(1)修改studentA类中各数据成员和成员函数的访问限定符,并观察发生的现象{public: StudentA(int n,string nam,char s); void showA(); ~StudentA( ) { }prot
2013-05-29 19:12:16 862 1
原创 Circle类派生Cylinderle类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 21 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using names
2013-05-21 09:06:27 940
原创 Point类派生Circle类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 21 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using names
2013-05-21 08:53:05 1274
原创 Point类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 21 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using names
2013-05-21 08:41:39 2793 1
原创 点类派生直线类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 21 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include#includeus
2013-05-21 08:27:57 763
原创 点类派生直线类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 21 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include#includeus
2013-05-21 08:18:02 936 1
原创 CEquation类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 7 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namespace std;clas
2013-05-07 11:26:54 852
原创 CFraction类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 7 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include #include using namespace s
2013-05-07 11:21:22 1777
原创 CTime类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 7 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namespace std;class
2013-05-07 11:17:08 1112
原创 Complex类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 5 月 7 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namespace std;class
2013-05-07 11:13:11 785
原创 分数类和整形数类的四则运算
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 19 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include#includeus
2013-04-19 10:20:07 874
原创 分数类中的运算符重载
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 19 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include#includeus
2013-04-19 10:14:28 799
原创 Time类中的运算符重载
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 19 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using names
2013-04-19 10:10:51 772
原创 扩展运算符功能,使之能与double型数据进行运算
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 18 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include class Complex {public:
2013-04-18 15:16:29 839
原创 用类的友元函数完成运算符的重载
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 18 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include class Complex {public:
2013-04-18 14:56:08 806
原创 用类的成员函数完成运算符的重载
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 18 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namespace std;clas
2013-04-18 13:43:46 719
原创 友元类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 17 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namespace std;class
2013-04-17 19:59:52 624
原创 时间类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 13 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namespace std;class
2013-04-13 22:58:42 530
原创 成员函数,友元函数和一般函数的区别
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 13 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include #include using namespace
2013-04-13 22:48:23 536
原创 改错
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 12 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include #include us
2013-04-12 10:02:13 436
原创 三角形类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013年 4 月 9 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include #include u
2013-04-09 09:17:08 504
原创 平面坐标点类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013 年 4 月 9 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include #include
2013-04-09 08:19:41 742
原创 指针类型作为成员函数的参数
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013 年 4 月 8 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include#includeus
2013-04-08 19:13:57 728
原创 用指针访问对象
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013 年 4 月 5 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include#includeus
2013-04-05 11:15:01 914
原创 改错2
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013 年 4 月 5 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include#includeus
2013-04-05 10:11:10 579
原创 改错1
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013 年 4 月 5 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include#includeus
2013-04-05 10:08:06 634
原创 长方柱类
/** 程序的版权和版本声明部分* Copyright (c)2012, 烟台大学计算机学院学生* All rightsreserved.* 文件名称: object.cpp* 作者:隋 鑫* 完成日期: 2013 年 3 月 29 日* 版本号: v1.0* 输入描述:无* 问题描述:* 程序输出:*/#include using namespace std;clas
2013-03-29 22:33:56 781
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人