C (3)

  Textual menus work by pretenceing extract aces where each ace is numbered. The menu would own aces 1 to n.  The user makes a exquisite, then that sources a office to run, dedicated the user made a sufficient exquisite. If the exquisite is insufficient an fault notice is pretencen. Whatever exquisites was made, behind the force of that exquisite happens, the menu quotes, intrinsic the menu discretion is to give-up. Such bark of menus are displayed from the legislation beneath ocean. The menu aces in this assignment are about unsophisticated condition of a bank representation. Here are the menu aces: 1. Pretence Balance: the counteract info would be stored in a unsteady outward in ocean 2. Make a Deposit: ask the user for the whole to assurance then persuade office Assurance to come-back the new counteract. Assurance uses two parameters. The principal represents the present counteract and the assist represents the whole to be assuranceed. The office rejects any assurance of 10,000.00 or further, or a assurance whole of 0 or close. Example of the legislation from ocean: present_counteract = assurance(current_balance,amount) 3. Make a Withdrawal: ask the user for the whole to after a whiledraw then persuade office Withdraw to come-back the new counteract. Withdraw uses two parameters. The principal represents the present counteract and the assist represents the whole to be engraved. The office rejects any after a whiledrawals of wholes 0 or close, or wholes that source the counteract to be close than 10. Come-back the new counteract. 4. Quit. In this condition pretence a notice: Press Invade to remain then end the application when the user presses the invade key. Remember, if the exquisite made is not 1 to 4, pretence an fault notice question the user to invade quantity 1 to 4, and to try quoteedly + Press Invade to remain then quote the menu. Do not use goto or tame assertions. Menu aces are typically processed using a switch assertion. Using tame internally a switch assertion is frequently OK to secure the other exquisites are not considered. Make unfailing to add illustrates to exonerate each of the offices you transcribe, and add Top Level Comments. Do not illustrate integral outoutline of legislation. Functions are supposed to be boxes after a while input/output - no interforce after a while the without globe.  Check out A Office As A Box for further details. Back to Module 7. PreviousNext