1 Star 1 Fork 0

CS-IMIS-23/20172313yukunpeng

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
Transactions.java 1.08 KB
一键复制 编辑 原始数据 按行查看 历史
余坤澎 提交于 7年前 . docs:practice
//**************************************************
// Transactions.java Author
//**************************************************
public class Transactions
{
//--------------------------------------------------------
// Creats some bank accounts and requests various services
//--------------------------------------------------------
public static void main(String[] args)
{
Account acct1 = new Account("Ted MUrphy", 72354, 102.56);
Account acct2 = new Account("Jane smith", 69713, 40.00);
Account acct3 = new Account("Edward Demsey", 93757, 759.32);
acct1.deposit(25.85);
double smithBalance = acct2.deposit(500.00);
System.out.println("smith balance after deposit: " + smithBalance);
System.out.println("Smith balance after withdrawal: " +
acct2.withdraw(430.75, 1.50));
acct1.addInterest();
acct2.addInterest();
acct3.addInterest();
System.out.println();
System.out.println(acct1);
System.out.println(acct2);
System.out.println(acct3);
}
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/CS-IMIS-23/20172313yukunpeng.git
git@gitee.com:CS-IMIS-23/20172313yukunpeng.git
CS-IMIS-23
20172313yukunpeng
20172313yukunpeng
master

搜索帮助