Browse over 20 million
homework answers & study documents

BIMS209 C# ASSIGNMENT 7 banking Console Application

Type

Lab

Rating

Showing Page:
1/5
Account.cs





 !"#!$
%
#
%
&'
&#(
&#('
'')*%+
'&)'&*
%
,)&-.!!*.&
.!
+
'#()*%#(+
'&#()&*%#(.&+
'#(')*%#('+
'&#(')&*%#('.&+
'#)*%+
'#)/0/'0'/'*
%
#()/*
#(')/'*
)/'*
+
'&&)'/*
%
1./
+
'&'2')'/*
%
,)/3!*
44(&('5)6&57(&'
6*
,)/-.!88/3.*
%
7./

+
445)69:6*
+
'&&;#)*
%
<)6#(=%!=+60#(*
<)6('=%!=(+60#('*

Sign up to view the full document!

lock_open Sign Up
<)6=%!=+60*
+
+
+
Savingsaccount.cs





 !"#!$
%
&#=#
%
&'>
''>)*%>+
'&>)'&*
%
,)&-.!*>.&
44(&('5)6&57(&'
6*
+
'&#)*%+
'&#)/0/'0?/'0'/*
=')/0/'0/'*
%
>./
+
'')*
%
>)*@)*
+
'&&;#)*
%
';#)*
<)6>=%!=(+60>*
+
+
+
CheckingAccount.cs





 !"#!$
%
#=#

Sign up to view the full document!

lock_open Sign Up

Sign up to view the full document!

lock_open Sign Up

Unformatted Attachment Preview

Account.csusing System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;namespace CSBIMS209Assignment07{ class Account { private double Balance; private string AccountName; private int AccountNumber; public double getBalance() { return Balance; } public void setBalance(double value) { if (value >= 0.0) Balance = value; else Balance = 0; } public string getAccountName() { return AccountName; } public void setAccountName(string value) { AccountName = value; } public int getAccountNumber() { return AccountNumber; } public void setAccountNumber(int value) { AccountNumber = value; } public Account() { } public Account(String p_name, int p_number, double p_balance) { setAccountName(p_name); setAccountNumber(p_number); setBalance(p_balance); } public virtual void Credit(double p_amount) { Balance += p_amount; } public virtual bool Debit(double p_amount) { if(p_amount<0) throw new NegativeNumberException("Invalid Entry - Negative numbers are not permitted."); else if (p_amount >=0 && p_amount <= Balance) { Balance -= p_amount; return true; } else throw new Exception("Insufficien ...
Purchase document to see full attachment

Anonymous
Had to paraphrase some of the content but overall, really useful material.

Anonymous
Thanks, good work

Anonymous
Heard about Studypool for a while and finally tried it. Glad I did caus this was really helpful.

Studypool
4.7
Trustpilot
4.5
Sitejabber
4.4