Question: Write a Java application to emulate a simple Automatic Teller Machine. This ATM must allow your customers to make cash withdrawals and check account balance,

Write a Java application to emulate a simple Automatic Teller Machine. This ATM must allow your customers to make cash withdrawals and check account balance, and deposit cash or checks while maintaining their latest balance. This is a perpetual ATM and cannot be shutdown.

Your program must perform the following:

1. Read the names, pin numbers, and account balances of 2 customers from the keyboard into appropriate variables. Ensue its success by outputting these values. The next step starts the ATM for one or more customers.

2. Display a welcome screen followed by a prompt for the user to enter a name and pin number.

3. If the entered information matches that of one of the two customers:

a. Welcome the customer by name.

b. Display the following choices:

i. Withdrawal

ii. Deposit

iii. Current balance

iv. Exit

4. Should the entered information not match that of any of your customers, inform the user that the entered information does not match existing customers and to try again._ Follow this by displaying of the original welcome screen (step 2).

5. If the Withdrawal option is selected, prompt the customer for the withdrawal amount, and when entered, echo the amount, display the latest balance, then prompt the user to enter M or m to view menu in step 3b or X or x to exit. Ensure the customer does not withdraw more than the current balance.

6. If the Deposit option is selected, prompt the customer for the deposit amount, and when entered, echo the deposit amount, display the latest balance, then prompt the user to enter M or m to view menu in step 3b or X or x to exit.

7. The Current balance option must display the current balance followed by a prompt to enter M or m to view menu in step 3b or X or x to exit.

8. Upon selecting Exit, the original login screen (step2) must display

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!