- 24
- 0
- 约1.66万字
- 约 61页
- 2018-06-21 发布于湖北
- 举报
DataBase类 Author,title,year Disp,构造函数 Painting类 Width,height Disp,构造函数 Music类 key Disp,构造函数 class DataBase { protected: char author[10];//作者 char title[20];//名字 int year;//年份 public: DataBase(char *author,char title[],int year) { strcpy(this-author,author); strcpy(this-title,title); this-year=year; } virtual void disp(); }; void DataBase::disp() { cout 作者:this-authorendl; cout 名字:this-titleendl; cout 年份:this-yearendl; } class Painting:public DataBase { private: int height,width; public: Painting(char *author,char *title,int year,int width,int height):DataBase(author,title,
您可能关注的文档
最近下载
- 2024-2025学年河南省洛阳市强基联盟高一下学期3月联考数学试卷(含答案).docx VIP
- 筏板基础施工组织设计砖混机构.doc VIP
- 产科临床诊疗指南及操作规范.docx VIP
- 中华人民共和国药品管理法实施条例2026版普法课件.pptx VIP
- 2022年江苏对口单招计算机专业试卷.doc VIP
- 2023年江苏省对口单招计算机专业综合理论试卷.doc VIP
- 短视频平台短视频脚本撰写培训.pptx VIP
- 2025年中国继发性肺动脉高压诊断与治疗指南解读PPT课件.pptx VIP
- 2023年江苏对口单招计算机专业试卷.pdf VIP
- 体育运动中的交流与合作 课件 -2024—2025学年人教版初中体育与健康七年级全一册.pptx VIP
原创力文档

文档评论(0)