Question
C# Programming: A commercial Bank wants to develop a C# application which will contain several classes. Among them, your responsibility is to develop the basic
C# Programming:
A commercial Bank wants to develop a C# application which will contain several classes. Among them, your responsibility is to develop the basic Account class with the specifications below:
Fields |
|
Properties |
|
AccountId | // read only property |
accountNumber | // read only property |
OwnerName |
|
Balance |
|
Constructor |
|
Account(accountNumber, OwnerName) | //initializes all the member variables // accountId is auto-genarated (format: [current_year].[month].[count]) (Example: 2016.06.1, 2016.06.2, etc.) //balance should be initialized to zero |
Methods |
|
Credit(amount) | //adds a valid amount to the balance |
Debit(amount) | //subtracts a valid amount from the balance |
Transaction(toAccount, amount) | //a valid amount is deposited to toAccount |
CheckBalance() | //returns balance of an account |
Note-1: Do not add any extra member to the class
Note-2: Need to implement the main method
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started