Determining the loop-decision structure

Assignment Help Basic Computer Science
Reference no: EM131274855

Java program showing a Loop, Decision Structure, and an array for a company that sells school supplies to children and prints out a receipt in a console window for the user at the end.

Children purchase no more than 10 school supplies at a time (so this should be the size of any arrays you have if you need a number depending on how you set it up.)

Here is the Table of things the person operating the Java Program can choose from based on what the child chooses:

Item Number

Item Name

Price

1

Box of Crayons

4.25

2

Pencil

.15

3

Paper

.05

4

Eraser

.10

Requirements:

1. The program should ask the user for the item number for an amount of items. The user should not directly enter the price. (You will need to use Ifs or a Switch Case decision structure to find that out.)

2. The loop needs to control the entry of the item choices one by one (you can ask the user for a number of items to enter or use a sentinel variable. It is up to you. You must demonstrate a loop though.)

3. The program should store the Item Names and Prices in separate arrays (or one message with both in a string array if you want to do it that way), and it should print out all of the items at the very end of the program when the program is over.

4. Finally, print the total of all the items the user selected. There should be a total for the supplies that are being purchased at this store.

Reference no: EM131274855

Questions Cloud

Explain whether or not the intruder is liable for his action : Explain whether or not the intruder is liable for his actions. Explain your legal duties and responsibilities to Sharon and Daryl. Differentiate among some of the potential torts that might arise from this business context. Discuss ways to prevent or..
Represented with each signal change : A carrier wave is modulated with 4 amplitudes and 4 phase changes; how many bits can be represented with each signal change?
Describe type of communication mechanism that can be adopted : Describe the types of communication mechanisms that can be adopted by Richard to help ensure better understanding and co-ordination not only with existing employees, but also with new employees?
How might parents schools the juvenile courts : How might parents, schools, the juvenile courts and service providers better communicate and work together to identify treatment and behavioral needs of juvenile offenders and to create cross-disciplinary approaches to case management?
Determining the loop-decision structure : Java program showing a Loop, Decision Structure, and an array for a company that sells school supplies to children and prints out a receipt in a console window for the user at the end.
Concerning the market test of the new cups and carriers : Concerning the market test of the new cups and carriers, I have a few suggestions that may be helpful, although the final decision is yours - During the third weekend we'll have someone make a survey at the store to determine its acceptance
What made the individuals professional : Describe and explain what you viewed. Answer the following questions in your response: Were the individuals professional? What made the individuals professional (consider attire, communication skills, presentation of self, etc.)?
Identify the resources required for implementation : Describe the range of available options from which a VPN solution can be selected. Identify the resources required for implementation.
Display the proper message on that and terminate : Display the user's name (first and last), hourly rate, hours worked, withholding tax percentage, withholding tax and gross pay. When a user is not an employee - display the proper message on that and terminate the application. Use logical AND and OR ..

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Identifies the cost of computer

identifies the cost of computer components to configure a computer system (including all peripheral devices where needed) for use in one of the following four situations:

  Input devices

Compare how the gestures data is generated and represented for interpretation in each of the following input devices. In your comparison, consider the data formats (radio waves, electrical signal, sound, etc.), device drivers, operating systems suppo..

  Cores on computer systems

Assignment : Cores on Computer Systems:  Differentiate between multiprocessor systems and many-core systems in terms of power efficiency, cost benefit analysis, instructions processing efficiency, and packaging form factors.

  Prepare an annual budget in an excel spreadsheet

Prepare working solutions in Excel that will manage the annual budget

  Write a research paper in relation to a software design

Research paper in relation to a Software Design related topic

  Describe the forest, domain, ou, and trust configuration

Describe the forest, domain, OU, and trust configuration for Bluesky. Include a chart or diagram of the current configuration. Currently Bluesky has a single domain and default OU structure.

  Construct a truth table for the boolean expression

Construct a truth table for the Boolean expressions ABC + A'B'C' ABC + AB'C' + A'B'C' A(BC' + B'C)

  Evaluate the cost of materials

Evaluate the cost of materials

  The marie simulator

Depending on how comfortable you are with using the MARIE simulator after reading

  What is the main advantage of using master pages

What is the main advantage of using master pages. Explain the purpose and advantage of using styles.

  Describe the three fundamental models of distributed systems

Explain the two approaches to packet delivery by the network layer in Distributed Systems. Describe the three fundamental models of Distributed Systems

  Distinguish between caching and buffering

Distinguish between caching and buffering The failure model defines the ways in which failure may occur in order to provide an understanding of the effects of failure. Give one type of failure with a brief description of the failure

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