-
account
设计一个名为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)
- 2013-06-01 13:21:54下载
- 积分:1
-
页面异常断点VEH
易语言进行 断点VEH 想断任何位置需要自己写分页和单步(If you want to break any position, you need to write your own pagination and single step)
- 2021-01-13 08:38:49下载
- 积分:1
-
java-neo4j
Java调用Neo4j图数据库实现增删改查的功能(Java calls Neo4j graph database to realize the function of adding, deleting, modifying and checking)
- 2021-01-19 23:58:42下载
- 积分:1
-
一个C++的中序遍历程序,输入一组数据后能中序遍历并升序输出。...
一个C++的中序遍历程序,输入一组数据后能中序遍历并升序输出。-one C and the preorder procedures, a data input after which preorder and ascending output.
- 2022-03-02 10:11:49下载
- 积分:1
-
基于S函数的BP神经网络PID控制器及Simulink仿真
神经网络控制,基于matlab编程算法。可以学习借鉴使用(Neural network control, based on MATLAB programming algorithm. You can learn from it.)
- 2020-11-11 15:09:45下载
- 积分:1
-
MCP3204
说明: 51单片机读取16位AD芯片MCP3204程序,可读取4路通道,程序中写了两路,可根据注释增加或减少通道数,1602显示,有Proteus仿真。(51 MCU reads 16-bit AD chip MCP3204 program, which can read 4 channels and write two channels. According to the annotation, the number of channels can be increased or reduced. 1602 shows that there is Proteus simulation.)
- 2019-06-28 13:13:11下载
- 积分:1
-
JPE 8-2-3
Coordination Strategies between HVDC STATCOM
- 2017-11-29 04:19:12下载
- 积分:1
-
frmSupplier.Designer
卓立汉光DHcam摄像头驱动与界面程序,包含C#源代码与visual studio工程文件(DHcam Camera Driver and Interface Program, including C# Source Code and Visual Studio Engineering File)
- 2020-06-25 02:20:02下载
- 积分:1
-
该文档详细介绍了c语言的基本知识,由浅入深,适合广大C语言编程爱好者的参考....
该文档详细介绍了c语言的基本知识,由浅入深,适合广大C语言编程爱好者的参考.-This document details the basic knowledge of c language, easy-to-digest, for the vast numbers of C language programming enthusiasts reference.
- 2022-06-19 10:19:22下载
- 积分:1
-
flmhd
fluent Magnetohydrodynamics (MHD) Module Manual
- 2018-05-06 00:46:15下载
- 积分:1