Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

In this lab, you use what you have learned about parallel arrays to complete a partially completed Java program. The program is described in Chapter 6, Exercise 7, in Programming Logic and Design. The program should either print the name and price for a coffee add-in from the Jumpin' Jive coffee shop or it should print the message: "Sorry, we do not carry that.". Read the problem description carefully before you begin. The data file provided for this lab includes the necessary variable declarations and input statements. You need to write the part of the program that searches for the name of the coffee add-in(s) and either prints the name and price of the add-in or prints the error message if the add-in is not found. You can use the expanded Mail Order2 program shown in Figure 6-6 as a guide.

1. Open the source code file named JumpinJive.java using Notepad or the text editor of your choice.

2. Study the prewritten code to make sure you understand it.

3. Write the code that searches the array for the name of the add-in ordered by the customer.

4. Write the code that prints the name and price of the add-in or the error message, and also write the code that prints the total order cost.

5. Save this source code file in a directory of your choice, and then make that directory your working directory.

6. Compile the source code file, JumpinJive.java.

7. Execute the program using the following data, and record the output: Cream Caramel Whiskey chocolate Chocolate Cinnamon Vanilla Remember that Java is case sensitive, which means it distinguishes between uppercase letters and lowercase letters. This means, for example, that Cinnamon is not the same as cinnamon.

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M92029908
  • Price:- $20

Priced at Now at $20, Verified Solution

Have any Question?


Related Questions in Computer Engineering

Sorting program note make sure you use c programmingfor

Sorting Program Note: Make sure you use c++ programming For this assignment, you are to write a comparative algorithm that will compare the efficiency of three sorting routines. Here is the approach you should use: 1. Wr ...

Now assume that this market becomes perfectly competitive

Now, assume that this market becomes perfectly competitive. The production process for the good does not change. So, all firms have the same cost curves as the monopolist. Reference from: Q3. A monopolist in the sugar ma ...

Describe the role of an ethical hacker and describe what

Describe the role of an ethical hacker and describe what you can do legally as an ethical hacker

Two one-cent coins were weighed on an electronic balance of

Two one-cent coins were weighed on an electronic balance of high sensitivity, and an average mass per coin of 2.4918 g was obtained from the data. How could you use the same number of significant figures as the value obt ...

All rsa cryptosystem has public key n 35 and e 7 messages

All RSA cryptosystem has public key N = 35 and e = 7. Messages are encrypted one letter at a time, converting letters to numbers by A = 2, B = 3, .... Z = 27, space = 28. Showing your working, encrypt the message: BE GOO ...

Discuss the criteria necessary to establish a factor as a

Discuss the criteria necessary to establish a factor as a confounder and provide an example applying these criteria?

Consider two computer companies - orange and ph - that

Consider two computer companies - Orange and PH - that report current sales receipts of $323 million and $294 million, respectively. Their cur-rent operating expenses were $150 million each. Orange issued $5 million in n ...

Why software is important in our lifesearch the internet

Why Software is important in our life? Search the internet for "Why Software is important in our life" Read about this topic and write an essay of around 500 words and submit it.

Jeff decides to start saving some money from this upcoming

Jeff decides to start saving some money from this upcoming month onwards. He decides to save only $500 at first, but each month he will increase the amount invested by $100. He will do it for 60 months (including the fir ...

The gravitational attraction between any two objects in the

The gravitational attraction between any two objects in the universe is given by the following formula: Force of Gravity = (G * m * n) / r 2 Where  m  and  n  are masses of the objects in kilograms,  r  is the distance b ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As