lab11 - Lab 11: Mini ATM Last Modified 12/17/2008 Key...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Lab 11: Mini ATM Last Modified 12/17/2008 Key Concept: do...while loop, nesting structures, preview of methods Write a program that handles many transactions at an ATM. Part I: Menu System [16 pts.] Start with a default balance of your choosing (i.e. how much was in the user's account). Use a CONSTANT for this and declare it globally. Present the user with a menu that looks like this: Enter an option: (W)ithdraw (D)eposit (B)alance Inquiry (Q)uit Use a switch structure to implement the menu. If the user asks to withdraw or deposit, ask for an amount and output a new balance. You'll need to keep track of the balance between transactions in doing so. You should treat lowercase options as valid, but you should also print out an error message for an invalid options. You don't need to worry about formatting the number of decimals in the output. The menu should run constantly until the user selects the 'Q' option. Use a do...while loop....
View Full Document

Page1 / 3

lab11 - Lab 11: Mini ATM Last Modified 12/17/2008 Key...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online