文件名称:Account
-
所属分类:
- 标签属性:
- 上传时间:2016-05-06
-
文件大小:229.22kb
-
已下载:1次
-
提 供 者:
-
相关连接:无下载说明:别用迅雷下载,失败请重下,重下不扣分!
介绍说明--下载内容来自于网络,使用问题请自行百度
一、实验名称:银行账户模拟
二、实验目的:这道题的主要目的是加深同学们对于面对对象编程中继承理解
三、实验内容:
创建一个银行账户的继承层次,表示银行的所有客户。所有的客户都能在他们的银行账户中存钱、取钱。任务主要如下:
(1)创建Account类,作为基类。Account类应该包含帐户余额,并提供构造函数;向账户中余额加钱的方法;减少账户中余额的方法;获取当前帐户余额的方法。
(2)创建Account类的派生类:储蓄账户SavingAccount类,除去基类Account的所有功能外,储蓄账户还应该具有新的特性。储蓄帐户应该提供一个计算利息的成员函数和将利息加到帐户余额上的操作。
(3)创建Account类的派生类:支票帐户CheckingAccount类,与储蓄账户不同的是,它没有利率的计算,但是它会在每笔交易后收取一定的交易费用。它需要重新定义基类Account中的成员函数,当每笔交易完成时,在帐户余额中减去交易金额。
(4)在提供上述方法时有出错情况的处理,比如帐户余额不足等情况。-First, the experiment name: Bank Account Demo Second, the purpose of the experiment: The main purpose of this question is to deepen the students to understand object-oriented programming, inheritance III Experiment: Create a hierarchy of bank accounts, indicating that all bank customers. All the customers can save money in their bank accounts, withdraw money. The main tasks are as follows: (1) Create Account class as a base class. Account class should contain account balances, and provide a constructor add money to the account balance method method of reducing the account balance acquisition method of the current account balance. (2) create a derived class Account class: savings account SavingAccount class, remove all the functionality of the base class Account, the savings account should also have new features. Savings account should provide a calculation of interest and the interest of the member function is added to the operating account balance on. (3) create a derived class Acc
二、实验目的:这道题的主要目的是加深同学们对于面对对象编程中继承理解
三、实验内容:
创建一个银行账户的继承层次,表示银行的所有客户。所有的客户都能在他们的银行账户中存钱、取钱。任务主要如下:
(1)创建Account类,作为基类。Account类应该包含帐户余额,并提供构造函数;向账户中余额加钱的方法;减少账户中余额的方法;获取当前帐户余额的方法。
(2)创建Account类的派生类:储蓄账户SavingAccount类,除去基类Account的所有功能外,储蓄账户还应该具有新的特性。储蓄帐户应该提供一个计算利息的成员函数和将利息加到帐户余额上的操作。
(3)创建Account类的派生类:支票帐户CheckingAccount类,与储蓄账户不同的是,它没有利率的计算,但是它会在每笔交易后收取一定的交易费用。它需要重新定义基类Account中的成员函数,当每笔交易完成时,在帐户余额中减去交易金额。
(4)在提供上述方法时有出错情况的处理,比如帐户余额不足等情况。-First, the experiment name: Bank Account Demo Second, the purpose of the experiment: The main purpose of this question is to deepen the students to understand object-oriented programming, inheritance III Experiment: Create a hierarchy of bank accounts, indicating that all bank customers. All the customers can save money in their bank accounts, withdraw money. The main tasks are as follows: (1) Create Account class as a base class. Account class should contain account balances, and provide a constructor add money to the account balance method method of reducing the account balance acquisition method of the current account balance. (2) create a derived class Account class: savings account SavingAccount class, remove all the functionality of the base class Account, the savings account should also have new features. Savings account should provide a calculation of interest and the interest of the member function is added to the operating account balance on. (3) create a derived class Acc
(系统自动生成,下载前可以参看下载内容)
下载文件列表
Account/account/account.cbp
Account/account/account.depend
Account/account/account.h
Account/account/accounttest.cpp
Account/account/bin/Debug/account.exe
Account/account/obj/Debug/accounttest.o
Account/实验报告.doc
Account/account/obj/Debug/C/Users/Administrator/Desktop/课件/C++/第六次作业
Account/account/obj/Debug/C/Users/Administrator/Desktop/课件/C++
Account/account/obj/Debug/C/Users/Administrator/Desktop/课件
Account/account/obj/Debug/C/Users/Administrator/Desktop
Account/account/obj/Debug/C/Users/Administrator
Account/account/obj/Debug/C/Users
Account/account/obj/Debug/C
Account/account/bin/Debug
Account/account/obj/Debug
Account/account/bin
Account/account/obj
Account/account
Account
Account/account/account.depend
Account/account/account.h
Account/account/accounttest.cpp
Account/account/bin/Debug/account.exe
Account/account/obj/Debug/accounttest.o
Account/实验报告.doc
Account/account/obj/Debug/C/Users/Administrator/Desktop/课件/C++/第六次作业
Account/account/obj/Debug/C/Users/Administrator/Desktop/课件/C++
Account/account/obj/Debug/C/Users/Administrator/Desktop/课件
Account/account/obj/Debug/C/Users/Administrator/Desktop
Account/account/obj/Debug/C/Users/Administrator
Account/account/obj/Debug/C/Users
Account/account/obj/Debug/C
Account/account/bin/Debug
Account/account/obj/Debug
Account/account/bin
Account/account/obj
Account/account
Account
本网站为编程资源及源代码搜集、介绍的搜索网站,版权归原作者所有! 粤ICP备11031372号
1999-2046 搜珍网 All Rights Reserved.