Design a complete algorithm or draw a flowchart

Assignment Help Data Structure & Algorithms
Reference no: EM13334399

1. You have the final sales figures for the four quarters in 2010 for Bennet's Used Auto Sales, and you are to design a program that asks for the sales figures, computes the total sales for the year, and calculates and displays the average quarterly sales for the year.

2.You've been asked to write a program that computes percentages for specific categories in a personal budget. The program should ask the user to enter estimated monthly expenditures for the following categories:
Rent Payment, Food, Utilities, and All Other. Your program should add the amounts, display the total, and compute and display the percentage for each category. Dollar amounts should be displayed with two decimal places and percentages should be displayed with one decimal place.

3. The manager of Guaranteed Gaskets has discovered a leak in the warehouse attic. It's raining, so he has placed a 25-liter bucket under the leak to catch the rain. He wants you to draw a flowchart for a program to keep track of the amount of rain accumulated in the bucket as long as it's raining.

Every 10 minutes, you're to check the water level in the bucket and record it in the program. If the level is 20 liters or higher, the program should display a message reminding you to empty the bucket and put it back. Otherwise, the program should display a message reminding you to come back in 10 minutes and run the program again.

Draw a flowchart for a program to display different messages based on the water level in the bucket.

4. Design a complete algorithm or draw a flowchart that determines the sales tax on purchases under $1.00 for a state with a 7% sales tax rate. Display the sales tax amount if the number of cents entered was 99 or less; otherwise, display an error message.

Instead of multiplying the amount of the sale by 7% and rounding, use the following list to determine the exact amount of sales tax:
-0 to 7 cents:no tax
-8 to 21 cents:1 cent tax
-22 to 35 cents: 2 cents tax
-36 to 49 cents: 3 cents tax
-50 to 64 cents: 4 cents tax
-65 to 78 cents: 5 cents tax
-79 to 92 cents: 6 cents tax
-93 to 99 cents: 7 cents tax
.

5. Before your boss allows adjustable thermostats in the office suite, he must be convinced that major temperature variations occur in different offices and within each office on different days. You're to write a program that allows each employee to enter the temperature at noon on each of five days and displays the highest, lowest, and average (mean) temperatures.

Draw a flowchart to accept five daily temperature readings and displays the highest, lowest, and average (mean) temperatures. Use a For loop to take the five readings. (Hint:Initialize the highest and lowest temperature variable to the first temperature that's read, and then compare other temperatures to see whether they're lower or higher.)

Reference no: EM13334399

Questions Cloud

Find the absolute pressure at the bottom of the container : A container is filled to a depth of 19.0 cm with water. On top of the water floats a 32.0-cm-thick layer of oil with specific gravity0.600
How to recognize the use and misuse of information presented : One of the concepts you encountered in the readings this module was how to recognize the use and misuse of information presented in the form of percentages. In this discussion assignment, you will conduct an Internet search to find several exa..
Explain the partial pressure of oxygen in the mixture : A gaseous mixture of O2 and N2 contains 38.8% nitrogen by mass. What is the partial pressure of oxygen in the mixture if the total pressure is 365mmHg
At what level of pretax cost savings would be indifferent : Your firm is contemplating the purchase of a new $703,000 computer-based order entry system. The system will be depreciated straight-line to zero over its 5-year life. It will be worth $68,400 at the end of that time.
Design a complete algorithm or draw a flowchart : Design a complete algorithm or draw a flowchart that determines the sales tax on purchases under $1.00 for a state with a 7% sales tax rate. Display the sales tax amount if the number of cents entered was 99 or less; otherwise, display an error me..
What are the net cash flows in years 0-1-2 and 3 : The project requires an initial investment in net working capital of $294,000. The project is estimated to generate $2,352,000 in annual sales, with costs of $940,800.
What is the average pressure on that area in atm : Someone steps on your toe, exerting a force of 300 N on an area of 1.1 cm2. What is the average pressure on that area in atm
Underlying statistical distribution for a p-chart : The underlying statistical distribution for a p-chart (yes-no attribute) is Binomial, but for large samples can be approximated by a Normal (bell-shaped) distribution. Why is this true?
Explain the rationale for recognizing costs as expenses : In some situations costs are recognized as expenses at the time of product sale; in other situations guidelines have been developed for recognizing costs as expenses or losses by other criteria.

Reviews

Write a Review

Data Structure & Algorithms Questions & Answers

  The binary search algorithm

- The "origin" of the Cartsian plane in math is the point where x and y are both zero. Declare a variable of type POINT named origin and set its data dields consistent with the mathematical notion of "origin".

  Determine expected number of collisions use hash function

Assume we use hash function h to hash n distinct keys into the array T of length m. Suppose simple uniform hashing, determine the expected number of collisions?

  Identify the most important facts about the diet

Identify the most important facts about the diet. State your opinion about the diet.Support your opinion with relevant facts or research

  Question about indexed strategy

Think about a file system on a disk that has both logical and physical block sizes of 512 bytes. Suppose that the data about each file is already in memory.

  Calculate failure and success ratios using fifo page removal

Using FIFO page removal algorithm, do a page trace analysis indicating page faults with asterisks (*). Then calculate the failure and success ratios.

  Representation of linked list

The table given below gives portion of a linked list. Every list entry spans two consecutive address locations the 1st contains a letter of the alphabet, and 2nd contains a pointer to the next list entry.

  Implement algorithm for evaluation of arithmetic expression

Implement the following algorithm for the evaluation of arithmetic expressions. Each operator has a precedence. The + and - operators have the lowest precedence.

  Creating database for a human resources group

Construct a database for a human resources group. List a few different tables and columns to store the HR information.

  Create the algorithm to read information through file

Create the algorithm which will read through file and compute numbers of married men, single men, married women and single women.

  Creating an automated checkout program

A local department store employee you to create an automated checkout program to expedite customers in a hurry. The checkout line can only allow 5-products for any one purchase.

  Write algorithm to prompt for and accept four numbers

Write the algorithm which will prompt for and accept four numbers, sort them into ascending sequence and display them to screen. Your algorithm is to include module called Order _two_numbers.

  Explain solution to recurrence-appealing to recursion tree

Solve the following recurrence relations by the method of your choiceT(n) = 1 for n = 4 and T(n) =pnT(pn) + n for n > 4. Argue that the solution to the recurrence T(n) = T(n=3) + T(2n=3) + cn is (n lg n) by appealing to the recursion tree.

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