问答题
试题五
阅读下列说明和C++-代码,将应填入 (n) 处的字句写在答题纸的对应栏内。
【说明】
某发票(lnvoice)由抬头(Head)部分、正文部分和脚注(Foot)部分构成。现采用装饰( Decorator)模式实现打印发票的功能,得到如图5-1所示的类图。
问题:5.1 【C++代码】
#include
using namespace std;
class Invoice{
public:
(1) {
cout<<"This is the content of the invoice!"<