From 8842db1df8211e0ddbf6cb5a7aac05512b134987 Mon Sep 17 00:00:00 2001 From: poopki Date: Tue, 12 Jul 2022 15:53:58 +0000 Subject: [PATCH] =?UTF-8?q?=EC=97=85=EB=8D=B0=EC=9D=B4=ED=8A=B8=20'Account?= =?UTF-8?q?Array.java'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- AccountArray.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/AccountArray.java b/AccountArray.java index f05ebb5..3c2deb4 100644 --- a/AccountArray.java +++ b/AccountArray.java @@ -13,8 +13,7 @@ public class AccountArray { Account m_Src = m_AccountArray.get(Src); Account m_Des = m_AccountArray.get(Des); - if(m_Src.getBalance()-Amount>0){ - m_Src.withdraw(Amount); + if(m_Src.withdraw(Amount)){ m_Des.credit(Amount); } }