登录
首页 » Visual C++ » account

account

于 2013-06-01 发布 文件大小:1KB
0 306
下载积分: 1 下载次数: 17

代码说明:

  设计一个名为Account类。这个类包含: (1)一个名为id的int型数据域,表示账户的身份号(默认值为0)。 (2)一个名为balance的double型数据域,表示账户余额(默认值为0)。 (3)一个名为annualInterestRate的double型数据域,保存当前年利率(默认值为0)。 (4)一个无实参构造函数,创建一个默认账户。 (5)id、balance和annualInterestRate的访问器和更改器函数。 (6)一个名为getMonthlyInterestRate()的函数,返回月利率。 (7)一个名为withDraw的函数,从账户中支取指定金额。 (8)一个名为deposit的函数,向账户中存入指定金额。 画出类的UML图,实现类。编写一个测试程序,它创建一个Account对象,其ID为1122,账户余额为20000,年利率为4.5 。使用withDraw函数取出2500美元,使用deposit函数存入3000美元,然后输出账户余额、月利率和账户创建时间。(Design a class named Account. This class includes: (a) a named data type int id field that indicates the account identification number (default is 0). (2) a double-called balance of data fields, which means that the account balance (default is 0). (3) a double type named annualInterestRate of data fields, save the current interest rate (default is 0). (4) a no-argument constructor creates a default account. (5) id, balance and annualInterestRate access control and change control functions. (6) a named getMonthlyInterestRate () function returns a monthly rate. (7) a function named withDraw, drawn from the account specified amount. (8) a function called deposit to the account into a designated amount. Draw a UML class diagram, the implementation class. Write a test program that creates an Account object, its ID is 1122, the account balance is 20,000, an interest rate of 4.5 . Use withDraw function out $ 2,500, $ 3,000 deposit with deposit function, and then outputs the account balance, m)

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • 97774083dnc_utf8
    数字转换工具,大写数字与小写数字的相互转换(Digital conversion tool, uppercase and lowercase digits digital conversion)
    2011-07-14 10:20:09下载
    积分:1
  • bigint
    实现大整数的加减乘除法运算,C++编写.比较简单(Realize large integer addition and subtraction, multiplication and division operations, C++ Prepared. Relatively simple)
    2008-05-20 22:06:51下载
    积分:1
  • pintu
    这是一个拼图游戏源码,课一实现3*3或4*4的拼图游戏,并给出时间,记录时间少的成绩。(This is a puzzle game source code, class one to achieve 3 or 4* 3* 4 jigsaw puzzle, and gives time to record less time results.)
    2011-11-09 15:50:50下载
    积分:1
  • Pham_Van_project_summary_report
    项目工作总结报告范文,项目的前期市场调研总结等例子,对项目管理人员有帮助(Pham Van project summary report)
    2010-09-03 14:20:50下载
    积分:1
  • longshou
    游戏代码,游戏名称为龙手,完成代码,如有问题请联系我(youxidaima ,ganxienindeshiyong)
    2013-02-26 23:50:25下载
    积分:1
  • duotaixingshiyan
    多态性实验,强烈建议大家来下载(Polymorphism of the experiment, we strongly recommend you to download)
    2009-01-01 11:05:30下载
    积分:1
  • Fishbot-3.3.5-master
    说明:  魔兽世界的一款自动挂机钓鱼工具 只支持3.35版本(Fishbot-3.3.5-master for wow 3.35)
    2020-08-17 19:16:06下载
    积分:1
  • sushuzl
    这是一个简单的求素数的程序,结构小巧简单,内容精炼.(Procedures for seeking prime number)
    2011-05-30 00:33:35下载
    积分:1
  • 小日历测试
    小日历窗口,如果日历窗口按照选择日期! 小日历窗口,如果日历窗口按照选择日期!(Small calendar window, if the calendar window according to the selected date! Small calendar window, if the calendar window according to the selected date!)
    2020-06-19 12:20:02下载
    积分:1
  • STM32F103RCT6矩阵键盘 矩阵按键
    说明:  STM32F103RCT6矩阵键盘,4×4键盘,按键串口打印(STM32F103RCT6 Matrix Keyboard, 4*4 Keyboard, Key Serial Port Printing)
    2020-06-19 02:00:01下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载