C++面向对象程序设计第七章(16)

2021-02-21 10:47

C++面向对象程序设计

1 2 3 4 5 6 7 8 9 11

// Fig. 13.5: fig13_05.cpp basederivedbase// Aiming base-class and derived-class pointers at base-class derived// and derived-class objects, respectively. #include <iostream> using std::cout; using std::endl; using std::fixed;

Outline

fig13_05.cpp

(1 of 5)<iomanip> #include <iomanip>

10 using std::setprecision; 12 // include class definitions 13 #include "CommissionEmployee.h" 14 #include "BasePlusCommissionEmployee.h" 15 16 int main() 17 { 18 19 20 21 22 23 base// create base-class pointer CommissionEmployee *commissionEmployeePtr = 0; base// create base-class object commissionEmployee( CommissionEmployee commissionEmployee( "Sue", "Jones", "222-22-2222", 10000, "Sue", "Jones", "222-22-2222", 10000, .06 );


C++面向对象程序设计第七章(16).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:医疗废物管理委员会组成、职责及会议制度

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: