Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

MATLAB PLEASE Problem 2: Bank Account Create an object oriented programing account class for a bank. Each account class contains the following information (properties): name

MATLAB PLEASEimage text in transcribedimage text in transcribed

Problem 2: Bank Account Create an object oriented programing account class for a bank. Each account class contains the following information (properties): name on the account, account type, balance, interest accrual rate, account number, pin number, and whether or not the account was locked by entering the incorrect pin. Also include an account number private property which cannot be changed and a pin property that can be reset but can't be viewed publicly As an example create an object: A bank customer with name 'A. Smith', account type checking, balance $5,000, yearly interest rate 1%, pin number 0101, account number 1234567, and account not locked (locked flag set to 0). Your class must include methods that do the following: When a customer makes a deposit of $5000 at the bank, add the deposit amount to the existing balance and show the updated balance and the information (non-private information) of the account. Calculate the interest made on the account this year if the interest is the balance yearly interest rate. Add this to the existing balance and display "The interest accrued this year is __ and the new balance is--"with the correct values shown. -When a customer wants to view the account balance, prompt the user for the pin number. If a customer enters the correct pin, show the account balance and account number. If a customer enters the incorrect display 'account locked' and set the locked flag to 1 . When a customer is locked out of their account, prompt them to enter the account number. If the account number is correct, prompt the user to set a new pin number and clear the locked flag by setting it to 0. If the customer enters the wrong account number, display 'Wrong account number, please try again later'. Problem 2: Bank Account Create an object oriented programing account class for a bank. Each account class contains the following information (properties): name on the account, account type, balance, interest accrual rate, account number, pin number, and whether or not the account was locked by entering the incorrect pin. Also include an account number private property which cannot be changed and a pin property that can be reset but can't be viewed publicly As an example create an object: A bank customer with name 'A. Smith', account type checking, balance $5,000, yearly interest rate 1%, pin number 0101, account number 1234567, and account not locked (locked flag set to 0). Your class must include methods that do the following: When a customer makes a deposit of $5000 at the bank, add the deposit amount to the existing balance and show the updated balance and the information (non-private information) of the account. Calculate the interest made on the account this year if the interest is the balance yearly interest rate. Add this to the existing balance and display "The interest accrued this year is __ and the new balance is--"with the correct values shown. -When a customer wants to view the account balance, prompt the user for the pin number. If a customer enters the correct pin, show the account balance and account number. If a customer enters the incorrect display 'account locked' and set the locked flag to 1 . When a customer is locked out of their account, prompt them to enter the account number. If the account number is correct, prompt the user to set a new pin number and clear the locked flag by setting it to 0. If the customer enters the wrong account number, display 'Wrong account number, please try again later

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Forensics Audits And Dreaming

Authors: Helgard Petrus - Coetser

1st Edition

1664260250, 978-1664260252

More Books

Students also viewed these Accounting questions

Question

What do the terms external customer and internal customer mean?

Answered: 1 week ago

Question

Evaluate the impact of unions on nurses and physicians.

Answered: 1 week ago

Question

Describe the impact of strikes on patient care.

Answered: 1 week ago

Question

Evaluate long-term care insurance.

Answered: 1 week ago