GRADED ACTIVITY #8 (M10.1): METHODS Instruction: Create a flowchart and a java program of the problem...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
GRADED ACTIVITY #8 (M10.1): METHODS Instruction: Create a flowchart and a java program of the problem stated as follows. Create user-defined methods that will perform 4 functionalities of an Automated Teller Machine (Withdraw, Deposit, Transfer, Balance Check) 1. Withdraw (method name: withdraw) *Input the amount to be withdrawn. Compute for the remaining balance after the operation (balance = balance - withdrawn) 2. Deposit (method name: deposit) *Input the amount to be deposited. Compute for the updated balance after the operation (balance = balance + deposit) 3. Transfer (method name: transfer) "Input the account number and the amount to be transferred. Compute for the updated balance after the operation (balance = balance - moneySent) 4. Balance Check (method name: balanceCheck) *Display the remaining balance. Sample Input/Output: Depicted below are sample outputs when the program is executed (the items in bold characters are input from the user, while the items in bold italic are calculated and printed by the program): -ATM-- 1. Withdraw 2. Deposit 3. Transfer 4. Check Balance 5. EXIT Choose operation: 1 Enter amount to be withdrawn: 1000 Collect your money Check Balance? (Y/N): Y Balance: 4000 1. Withdraw 2. Deposit 3. Transfer 4. Check Balance 5. EXIT -ATM- Choose operation: I Enter amount to be withdrawn: 6000 Insufficient Balance Check Balance? (Y/N): Y Balance: 4500 -ATM 1. Withdraw 2. Deposit 3. Transfer 4. Check Balance 5. EXIT Choose operation: 2 Enter amount you want to deposit: 500 Check Balance? (Y/N): N 1. Withdraw 2. Deposit 3. Transfer --ATM- 4. Check Balance 5. EXIT Choose operation: 3 Enter Account Number: 0566323454 Enter Transfer Amount: 300 Check Balance? (Y/N): Y Balance: 3200 *Note: The initial balance is 0. The user is given an option to check the balance or not. The program will run until the exit option is chosen. Required: The flowchart, the java file (FamilyName_ATM.java) containing the code and 4 (or more) image files (Sample1, Sample2, Sample3, and Sample4) containing different sample input/output of the program. GRADED ACTIVITY #8 (M10.1): METHODS Instruction: Create a flowchart and a java program of the problem stated as follows. Create user-defined methods that will perform 4 functionalities of an Automated Teller Machine (Withdraw, Deposit, Transfer, Balance Check) 1. Withdraw (method name: withdraw) *Input the amount to be withdrawn. Compute for the remaining balance after the operation (balance = balance - withdrawn) 2. Deposit (method name: deposit) *Input the amount to be deposited. Compute for the updated balance after the operation (balance = balance + deposit) 3. Transfer (method name: transfer) "Input the account number and the amount to be transferred. Compute for the updated balance after the operation (balance = balance - moneySent) 4. Balance Check (method name: balanceCheck) *Display the remaining balance. Sample Input/Output: Depicted below are sample outputs when the program is executed (the items in bold characters are input from the user, while the items in bold italic are calculated and printed by the program): -ATM-- 1. Withdraw 2. Deposit 3. Transfer 4. Check Balance 5. EXIT Choose operation: 1 Enter amount to be withdrawn: 1000 Collect your money Check Balance? (Y/N): Y Balance: 4000 1. Withdraw 2. Deposit 3. Transfer 4. Check Balance 5. EXIT -ATM- Choose operation: I Enter amount to be withdrawn: 6000 Insufficient Balance Check Balance? (Y/N): Y Balance: 4500 -ATM 1. Withdraw 2. Deposit 3. Transfer 4. Check Balance 5. EXIT Choose operation: 2 Enter amount you want to deposit: 500 Check Balance? (Y/N): N 1. Withdraw 2. Deposit 3. Transfer --ATM- 4. Check Balance 5. EXIT Choose operation: 3 Enter Account Number: 0566323454 Enter Transfer Amount: 300 Check Balance? (Y/N): Y Balance: 3200 *Note: The initial balance is 0. The user is given an option to check the balance or not. The program will run until the exit option is chosen. Required: The flowchart, the java file (FamilyName_ATM.java) containing the code and 4 (or more) image files (Sample1, Sample2, Sample3, and Sample4) containing different sample input/output of the program.
Expert Answer:
Answer rating: 100% (QA)
import javautilScanner public class ATMTransaction public static void mainString args int balance 50... View the full answer
Related Book For
Income Tax Fundamentals 2013
ISBN: 9781285586618
31st Edition
Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill
Posted Date:
Students also viewed these programming questions
-
Design a Java class that represents a cache with a fixed size. It should support operations like add, retrieve, and remove, and it should evict the least recently used item when it reaches capacity.
-
Write a program HowMany that takes a variable number of command-line arguments and prints how many there are.
-
Incomplete and adapted versions of the financial statements of Beach Paradise Corp. follow (amounts in thousands). Ratio data: Current ratio at December 31, 2017, is 0.7547. Inventory turnover for...
-
The Owner of Big Boy Flea Market (BBFM), Lewis Redding, passed away on December 30, 2014. His 100% ownership interest in BBFM became part of his estate, on which his heirs must pay estate taxes. The...
-
A standard nuclear power plant generates \(3.0 \mathrm{GW}\) of thermal power from the fission of \({ }^{235} \mathrm{U}\). Experiments show that, on average, \(0.19 \mathrm{u}\) of mass is lost in...
-
Recording Adjusting Entries and Reporting Balances in Financial Statements Aubrae Company is making adjusting entries for the year ended December 31, 2011. In developing information for the adjusting...
-
Chuck, a single taxpayer, earns $78,000 in taxable income and $13,300 in interest from an investment in City of Heflin bonds. (Use the U.S. tax rate schedule.) Required: a. If Chuck earns an...
-
A golf ball is launched with the initial conditions shown in the figure. Determine the radius of curvature of the trajectory and the time rate of change of the speed of the ball (a) just after launch...
-
structure. H B 4.5 2.00 11 The H NMR spectrum of a compound having a molecular formula of C4H8O. Determine the DBE and 4.0 3.5 0.72 3.0 2.5 2.0 ppm 1.5 3.05 1.0 Double bond equivalents: 0.5 Final...
-
What is the output of the following code? public void print(X Set set new HashSet (); set.add("1"); set.add(1) set.add(null): set.add(null): System.out.println(set):
-
The liberal version of the familiar view of international politics includes a place for international law. Using Traisbach (1-B-1), explain what we mean by international law, give some examples of...
-
What is the domain of the function f(x) = x+2 = ? \x\-1
-
What is international law?" Is international law really "law?" Why or why not? Support your answer with authoritative sources. How are the rules of international law made, and where can they be...
-
What is customary international law, how did it develop, and why is it important to international law more broadly? Name one specific example of a treaty or convention that would not exist without...
-
22% adults favor the use of unmanned drones by police agencies. Twelve U.S. adults are randomly selected. Find the probability that the number of U.S. adults who favor the use of unmanned drones by...
-
Apply Jacobis method to the given system. Take the zero vector as the initial approximation and work with four-significant-digit accuracy until two successive iterates agree within 0.001 in each...
-
Bea Jones (age 32) moved from Texas to Florida in December 2011. She lives at 654 Ocean Way, Gulfport, FL 33707. Bea's Social Security number is 466-78-7359 and she is single. Her earnings and income...
-
Jim is fired from his job as a waiter and decides to take an extended trip to Europe. After touring Europe for 3 months, Jim returns to look for a new job as a waiter. Are his job-hunting expenses...
-
Diane is a single taxpayer who qualifies for the earned income credit. Diane has two qualifying children who are 3 and 5 years old. During 2012, Diane's wages are $17,100 and she receives dividend...
-
Using Table 14.1 as a guide, do the following: A. Identify a topic for a presentation. B. Write how you could use each type of attention-getter: rhetorical question, vivid example, dramatic...
-
A. Identify a topic for a presentation. B. Write a positioning statement. C. Write a preview statement.
-
Identify a topic of interest. Create a storyboard to outline the titles, content, and related story line of your PowerPoint slides.
Study smarter with the SolutionInn App