自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(57)
  • 收藏
  • 关注

原创 十七周 任务一

源程序:#include#include using namespace std;class Student{public:Student(void){}Student(char nam[20], double cs, double mas, double ens, double all, double avs):cscore(cs), mathscore(mas),

2012-06-11 18:23:16 2785 1

原创 第十六周实验报告 任务三(改)

源程序:#include #include #include #include using namespace std;class Word{public: Word(); Word(string w, string t, string ci):word(w), translate(t), wordtype(ci){} string get_word(); str

2012-06-06 22:50:24 1586

原创 第十六周实验报告 任务三(最简)

源程序·:#include #include #include #include using namespace std;class Word{public: Word() { word = 'a'; translate = 'a'; cixing = 'a'; } Word(string w, string t, string ci):word(w),

2012-06-05 01:43:34 1250 1

原创 To my teacher...

When i saw the topic what the helao gave to us, my heart was really being shocked!!! I found i was so many words want to express, but i even didn't konw how to start a title.And i also didn't dear to

2012-06-04 01:15:09 1917 1

原创 十六周实验报告 任务二

源程序:#include #include #include #include using namespace std;class Student{public: Student() { name = 'a'; cscore = 0; mathscore = 0; englishscore = 0; sumscore = 0; averagesc

2012-06-03 10:51:53 4405

原创 十六周实验报告 任务一

源程序:#include #include #include using namespace std;int main(){ ifstream infile("salary.txt",ios::in); if(!infile) { cerr << "open error!!!"; exit(0); } double a[500], t; int i, j;

2012-06-02 15:08:01 864 1

原创 第十五周实验报告 任务三

3.1源代码:#include #include using namespace std;int main(){ int a; cout<<"input a:"; cin>>a; cout<<"dec:"<<dec<<a<<endl;//以十进制的形式输出输入的数~ cout<<"hex:"<<hex<<a<<endl;//以十六进制的形式输出输入的数(123456789a

2012-05-28 22:45:09 687

原创 第十五周实验报告 任务一

源程序:triangleDlg.cpp// triangle3Dlg.cpp : 实现文件//#include "stdafx.h"#include "MyTriangle.h"#include "triangle3.h"#include "triangle3Dlg.h"#ifdef _DEBUG#define new DEBUG_NEW#endif// 用于

2012-05-27 13:23:14 622

原创 第十五周实验报告 任务二

源程序:CFractionDlg.cpp// CFractionDlg.cpp : 实现文件//#include "stdafx.h"#include "MyCFraction.h"#include "CFraction.h"#include "CFractionDlg.h"#ifdef _DEBUG#define new DEBUG_NEW#endif//

2012-05-27 13:11:27 1037 1

原创 第十四周实验报告 任务一

源程序:#include using namespace std;class MyArray{private: int *arr; //用于存放动态分配的数组内存首地址 int size; //数组大小public: MyArray(int sz=50) { size = sz; arr = new int[size]; for(int i = 0; i <

2012-05-22 16:19:33 730 1

原创 第十三周实验报告 任务二(3)改

源程序:#include "iostream"#includeusing namespace std;class Animal{public: virtual void cry() = 0;/*{cout<<"不知哪种动物,让我如何学叫?"<<endl;}*/ Animal(string na); virtual ~Animal();protec

2012-05-14 18:30:26 631 1

原创 第十三周实验报告 任务四

源程序:#include#includeusing namespace std;const double P = 3.14;class CSolid//定义虚基类{public: virtual double area() const = 0;//定义纯虚函数 virtual double volume() const = 0;//定义虚函数};cl

2012-05-14 13:30:50 722

翻译 第十三周实验报告 任务三

源程序:#include#includeusing namespace std;const double P = 3.14;class Shape//定义虚基类{public: virtual double area() const = 0;//定义纯虚函数};class Circle:public Shape//定义圆类{public:

2012-05-14 13:25:47 684

原创 第十三周实验报告 任务二(3)

源程序:#include "iostream"#includeusing namespace std;class Animal{public: virtual void cry() = 0;/*{cout<<"不知哪种动物,让我如何学叫?"<<endl;}*/ protected: string name;};class Mouse:public

2012-05-14 13:22:10 610 1

原创 第十三周实验报告 任务二(2)

源程序: #include "iostream"#includeusing namespace std;class Animal{public: virtual void cry() = 0;/*{cout<<"不知哪种动物,让我如何学叫?"<<endl;}*/};class Mouse:public Animal{public: Mouse

2012-05-14 13:06:56 701

原创 第十三周实验报告 任务二(1)

源程序:#include "iostream"#includeusing namespace std;class Animal{public: virtual void cry() {cout<<"不知哪种动物,让我如何学叫?"<<endl;}};class Mouse:public Animal{public: Mouse(string na)

2012-05-14 12:53:37 610

原创 第十三周实验报告 任务一

源程序:#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

2012-05-14 12:38:43 641 1

原创 第十周实验报告 任务三(改)

源程序:#include#include//#define P 3.14 宏定义是c语言里的····const double P = 3.14;//c++应该用constusing namespace std;class Point //定义坐标点类{protected: double x, y; //点的横坐标和纵坐标pu

2012-04-23 19:25:44 699

原创 第十周实验报告 任务三

源程序:#include#include#define P 3.14using namespace std;class Point //定义坐标点类{protected: double x, y; //点的横坐标和纵坐标 public: Point(double x0, double y0):x(x0), y(y0){}

2012-04-21 20:54:17 707

原创 第十周实验报告 任务二

源程序:#include #include #include //setw:设置输出数据的宽度,使用时应#include using namespace std;class CPerson {protected: char *m_szName; char *m_szId; int m_nSex;//0:women,1:man

2012-04-21 18:56:49 675 1

原创 第十周实验报告 任务一

源程序:#include#includeusing namespace std;class Point //定义坐标点类{public: double x,y; //点的横坐标和纵坐标 Point(){x=0;y=0;} Point(double x0,double y0) {x=x0; y=y0;} void Pr

2012-04-21 16:37:49 643 1

原创 第九周实验报告 任务五

源程序:#include using namespace std;class CEquation{private: double a; // 未知数系数 double b; // 常数项 char unknown; // 未知数的符号public: CEquation(double aa=0,double bb=0

2012-04-16 20:27:19 396

原创 第九周实验报告 任务三

源程序:#include//using namespace std;class CFraction{private: int nume; // 分子 int deno; // 分母 public: CFraction(int

2012-04-16 20:24:09 381

原创 第九周实验报告 任务二

源程序:#include//using namespace std;class CTime{private: /*unsigned short */int hour; /*unsigned short */int minute; /*unsigned short */int second; public: CTime(in

2012-04-16 20:18:53 354

翻译 第九周实验报告 任务一

源程序:#include//using namespace std;class Complex{public: Complex(){real = 0;imag = 0;} Complex(double r, double i){real = r; imag =i;} friend Complex operator+(Complex &c1,

2012-04-16 20:14:40 448

原创 第八周实验报告 任务四(改)

源程序:#include//using namespace std;class CFraction{private: int nume; // 分子 int deno; // 分母 public: CFraction(int nu=0,int de=

2012-04-09 23:41:22 303

原创 第八周实验报告 任务三(改)

源程序:#includeusing namespace std;class CFraction{private: int nume; // 分子 int deno; // 分母 public: CFraction(int nu=0,int de=1)

2012-04-09 23:36:22 474

原创 第八周实验报告 任务二(改)

源程序:#includeusing namespace std;class CTime{private: /*unsigned short */int hour; /*unsigned short */int minute; /*unsigned short */int second;public: CTime(int h = 0

2012-04-09 19:12:10 354

原创 第八周实验报告 任务四

源程序:#includeusing namespace std;class CFraction{private: int nume; // 分子 int deno; // 分母 public: CFraction(int nu

2012-04-09 19:06:25 371

原创 第八周实验报告 任务三

源程序:#includeusing namespace std;class CFraction{private: int nume; // 分子 int deno; // 分母 public: CFraction(int nu

2012-04-08 18:03:28 470

原创 第八周实验报告 任务二

源程序:#includeusing namespace std;class CTime{private: /*unsigned short */int hour; /*unsigned short */int minute; /*unsigned short */int second; public: CTime(int

2012-04-07 20:59:43 420

原创 第八周实验报告 任务一

源程序:#includeusing namespace std;class Complex{public: Complex(){real = 0;imag = 0;} Complex(double r, double i){real = r; imag =i;} Complex operator+(Complex &c2);/

2012-04-07 20:50:24 728 2

翻译 第七周实验报告 任务三

源程序:#include using namespace std;templateclass Complex {public: Complex( ){real=0;imag=0;} Complex(T r,T i){real=r;imag=i;} Complex complex_add(Complex &c2);

2012-04-03 15:43:20 749 2

原创 第七周实验报告 任务二

源程序:#include#includeusing namespace std;class CPoint { public: CPoint(double xx=0,double yy=0):x(xx),y(yy){} double distance1(CPoint &p);//成员函数的声明 friend double

2012-04-03 15:38:22 479

翻译 第七周实验报告 任务一

源程序:#include#includeusing namespace std;class Time{public: Time(int=0,int=0,int=0); void show_time( ); //根据is_24和from0,输出适合形式-20:23:5/8:23:5 pm/08:23:05 pm void add_se

2012-04-03 15:29:37 477

原创 第六周实验报告 任务五

源程序://main.cpp#include#include "class.h"#includeusing namespace std;void main(){ CPoint p1, p2, p3; CTriangle tri(p1, p2, p3); double b1, b2, b3; while(1) { p1.input();

2012-03-28 22:54:52 360

原创 第六周实验报告 任务四

源程序:#include#includeusing namespace std;class CPoint{private: mutable double x; // 横坐标 mutable double y; // 纵坐标 public: CPoint(double xx=0,double yy=0); dou

2012-03-27 18:53:14 611 2

原创 第六周实验报告 任务三(改进)

源代码:#include#includeusing namespace std;enum SymmetricStyle { axisx,axisy,point};//分别表示按x轴, y轴, 原点对称class CPoint{private: mutable double x; // 横坐标 mutable double y; /

2012-03-27 18:26:57 392

翻译 第六周实验报告 任务三(自己做的···)

源代码:#include#includeusing namespace std;enum SymmetricStyle { axisx,axisy,point};//分别表示按x轴, y轴, 原点对称class CPoint{private: mutable double x; // 横坐标 mutable double y; /

2012-03-27 18:21:46 388

原创 第六周实验报告 任务二

源程序:#includeusing namespace std;class A {private: int a;public: A() {a=0;} A(int aa):a(aa){} //定义构造函数,用参数aa初始化数据成员a};void main() { A *p;//定义类A的指针对象p p = new A(6);

2012-03-27 18:15:04 572 1

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除