To make a profit, the items sold in a furniture store are marked up by 70%. After marking up the prices, each item is put on sale at a discount of 15%. Design an algorithm to find the final selling price of an item sold at the furniture store. Please write all steps in the algorithm beginning with inputting the initial price. Do each part of the percentages individually and don’t calculate and use the relative percentage. Write this in algorithm format not program code format.

Did I solve this correctly?

1. Input the furniture price
2. Inputed furniture price x .70 = mark up
3. Take the previous total x .15 = discount
4. Take previous total and subtract it from furniture price = selling price

Note: this isn't my actual algorithm. I am making sure my math is correct.

Respuesta :

By a simple construction of each step, we will see that the algorithm is:

  1. x = input value  (input the furniture cost)
  2. y = 1.7*x              (compute the markup value)
  3. z = 0.85*y           (apply the 15% discount).

How to write the algorithm?

The general algorithm will need the user to give an input, which will be the furniture cost, and then we will apply the correspondent increase/decrease to get the final value.

So the first step is to input the furniture cost.

1) x = input value of the furniture cost.

Then we apply the increase of the 70% increase, this means that we multiply it by 1.7

2) y = x*1.7

Notice that we defined a new variable, in the actual code you could use the same one.

Now we apply the decrease of the 15%, this means that we multiply by:

1 - 0.15 = 0.85

3) z = 0.85*y

Here we apply the discount to the markup price, not to the cost of the furniture which was the original input (and what you wrote in your algorithm).

Then the complete algorithm is:

  1. x = input value  (input the furniture cost)
  2. y = 1.7*x              (compute the markup value)
  3. z = 0.85*y           (apply the 15% discount).

And z would be the final price of the furniture item.

If you want to learn more about algorithms, you can read:

https://brainly.com/question/11623795

Q&A Education