资源简介
设计一个类SavingsAccount,定义一个静态数据成员记录存款的年利率(rate),该类的每个成员都包含一个私有的数据成员balance,表示该成员当前的存款数额。提供一个成员函数CalMonthlyInterest(),用以计算月利息(用balance乘以rate再除以12),并将这个月利息加入balance中。提供一个静态成员函数ModifyRate(),用以改变静态数据成员rate的值。定义两个不同的SavingsAccount对象saver1和saver2,当前存款数额balance分别为2000.00和3000.00。首先将rate设置为3%,计算每个存款人的月息并打印新的结果,然后将rate设置为4%,再次计算每个存款人的月息并打印新的结果。

代码片段和文件信息
// stdafx.cpp : source file that includes just the standard includes
// test3.pch will be the pre-compiled header
// stdafx.obj will contain the pre-compiled type information
#include “stdafx.h“
// TODO: reference any additional headers you need in STDAFX.H
// and not in this file
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 1202 2011-05-23 21:20 test3\test3\ReadMe.txt
文件 292 2011-05-23 21:20 test3\test3\StdAfx.cpp
文件 769 2011-05-23 21:20 test3\test3\StdAfx.h
文件 1312 2011-05-23 21:41 test3\test3\test3.cpp
文件 4524 2011-05-23 21:20 test3\test3\test3.dsp
文件 533 2011-05-23 21:20 test3\test3\test3.dsw
文件 33792 2011-05-23 21:41 test3\test3\test3.ncb
文件 48640 2011-05-23 21:41 test3\test3\test3.opt
文件 903 2011-05-23 21:41 test3\test3\test3.plg
文件 1817 2011-05-23 21:24 test3\test3\Debug\StdAfx.obj
文件 532521 2011-05-23 21:41 test3\test3\Debug\test3.exe
文件 771652 2011-05-23 21:41 test3\test3\Debug\test3.ilk
文件 150389 2011-05-23 21:41 test3\test3\Debug\test3.obj
文件 213872 2011-05-23 21:24 test3\test3\Debug\test3.pch
文件 1082368 2011-05-23 21:41 test3\test3\Debug\test3.pdb
文件 74752 2011-05-23 21:41 test3\test3\Debug\vc60.idb
文件 110592 2011-05-23 21:41 test3\test3\Debug\vc60.pdb
目录 0 2011-05-25 17:08 test3\test3\Debug
目录 0 2011-05-25 17:08 test3\test3
目录 0 2011-05-25 17:08 test3
----------- --------- ---------- ----- ----
3029930 20
- 上一篇:GRE红宝书pdfZIP版
- 下一篇:带通采样的原理和应用
相关资源
- Design of Analog CMOS Integrated Circuits 拉扎
- Effect of dietary nitrate dosage on gas produc
- 网络存储与硬盘业令Xyratex喜忧参半
- Xyratex欲部分收购Ario的RAID代码
- Novel fluorescent proteins generated by de nov
- Bioleaching of chalcopyrite and marmatite by m
- 音频测试文件pcmmp3aacamrg711ag711u等多种
- Existence of Solutions for Degenerate Elliptic
- Nortel Integrated DECT Handset 4025产品手册(
- Parametric investigation on thermally driven e
- Synthesis of Cyclohexanone-formaldehyde Resi
- 狼群算法Multi-strategy ensemble grey wolf
- Anti-CD3 antibody treatment ameliorates transf
- Analog Circuit Design:Discrete & Integrated (
-
Accurate subpixel edge location ba
sed on pa - 数据不均衡问题经典文献《Learning f
- Multirate Signal Processing for Communication
- Algorithmic Trading Winning Strategies and The
- unmanned systems integrated roadmap2017-2042
- ABB Robotstudio集成视觉手册(中文)
- automotive electronic architectures of integra
- pipe相关操作.doc
- Interest Rate Models – Theory and Practice W
- Joel Watson - Strategy solution manual
- Corporate Information Factory 2nd Edition
- Interest Rate Markets - A Practical Approach t
- Analysis and Design of Analog Integrated Circu
- vgg_generated_48(6480120).i
- Analysis and Design of Analog Integrated Circu
- Radio Frequency Integrated Circuit Design 第2版
评论
共有 条评论