Write menu driven program that make coffee shop operational

Assignment Help C/C++ Programming
Reference no: EM13723855

Jason opened a coffee shop at the beach and sells coffee in three sizes: small (9 oz), medium (12 oz), and large (15 oz). The cost of one small cup is $1.75, one medium cup is $1.90, and one large cup is $2.00. Write a menu-driven program that will make the coffee shop operational. Your program should allow the user to do the following:

a. Buy coffee in any size and in any number of cups.

b. At any time show the total number of cups of each size sold.

c. At any time show the total amount of coffee sold.

d. At any time show the total money made.

Your program should consist of at least the following functions: a function to show the user how to use the program, a function to sell coffee, a function to show the number of cups of each size sold, a function to show the total amount of coffee sold, and a function to show the total money made. Your program should not use any global variables. Special values such as coffee cup sizes and cost of a coffee cup must be declared as named constants.

Note: A menu-driven program offers the user a list of choices and a way to enter one of the choices. (The list could be numbered, or a letter could be associated with each choice.) The user enters a choice, and the program carries it out, then the program presents the menu again, so the user can make another selection. In addition to the four options listed above, the fifth choice must be

e. At any time quit the program.

The program loops until the user selects "quit" from the menu.

The first function specified above is the one which outputs the menu to the user, prompts the user to make a choice, and reads the user's input.  It can be a value-returning function, returning the user's input to main where the user's choice is tested to determine which function should be called next.

Reference no: EM13723855

Questions Cloud

Demonstrate a critical awareness of previous research : Demonstrate a critical awareness of previous research in an IT context within a chosen topic area through a basic understanding of research theory and techniques.
Investment has successfully increased shareholder wealth : What indications of financial performance must a company consider in evaluating whether an investment has successfully increased shareholder wealth?
Explains the causes of criminal behavior in urban areas : The cultural deviance theory explains the causes of criminal behavior in urban areas are not about the poverty suffered in those areas but the product of a distinct lower-class culture.
Why do people use social networks : Cyworld: Creating and Capturing Value in a Social Networkcase discussion questions and submission requirements: Why do people use social networks
Write menu driven program that make coffee shop operational : Write a menu-driven program that will make the coffee shop operational and Buy coffee in any size and in any number of cups.
All maturities and the dividend yield on the index : A stock index is currently 1,500. Its volatility is 18%. The risk-free rate is 4% per annum (continuously compounded) for all maturities and the dividend yield on the index is 2.5%. Calculate values for u, d, and p when a 6-month time step is used. W..
What roles did northern women play in the war : What roles did Northern women play in the war effort on the Union side during the Civil War? What roles did Southern women play in the war effort on the Confederate side during the Civil War?
Assignment on athletic gear project : Assignment on Athletic Gear Project, Explain each deliverable, incuding why it is important to provide that grade, instead of a higher or lower grade.
Perform a swot analysis of estern gear : Perform a SWOT analysis of Estern Gear. In doing so identify what you believe their distinctive competence is or should be?

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Create program that uses functions and reference parameters

Create program that uses functions and reference parameters, and asks user for the outside temperature.

  Write a program using vectors and iterators

Write a program using vectors and iterators that allows a user to maintain a personal list of DVD titles

  Write the code required to analyse and display the data

Calculate and store the average for each row and column. Determine and store the values for the Average Map.

  Write a webservices application

Write a webservices application that does a simple four function calculator

  Iimplement a client-server of the game

Iimplement a client-server version of the rock-paper-scissors-lizard-Spock game.

  Model-view-controller

Explain Model-View-Controller paradigm

  Design a nested program

How many levels of nesting are there in this design?

  Convert celsius temperatures to fahrenheit temperatures

Write a C++ program that converts Celsius Temperatures to Fahrenheit Temperatures.

  Evaluate and output the value in the given base

Write C program that will input two values from the user that are a Value and a Base with which you will evaluate and output the Value in the given Base.

  Design a base class shape with virtual functions

Design a base class shape with virtual functions

  Implementation of classes

Implementation of classes Chart and BarChart. Class barChart chould display a simple textual representation of the data

  Technical paper: memory management

Technical Paper: Memory Management, The intent of this paper is to provide you with an in depth knowledge of how memory is used in executing, your programs and its critical support for applications.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd