I need to program the following:

A company generates 61 percent of total sales. How much will the company generate if the company has $4.5 million in sales this year?

I am new at programming and I have no clue where to start:

Printable View

- 01-30-2003survivorPlease Someone Help
I need to program the following:

A company generates 61 percent of total sales. How much will the company generate if the company has $4.5 million in sales this year?

I am new at programming and I have no clue where to start: - 01-30-2003FillYourBrain
it's not really clear what you're asking. we won't do your homework but we will tell you this...

start by figuring out what the user will need to input, what the computer will need to figure out, and what the computer will need to display. Write a flowchart. Once you have a flowchart, start figuring out what code it will take to accomplish each step in the flowchart.

When you have something written, come back and ask a question. - 01-30-2003carrja99Re: Please Someone HelpQuote:

*Originally posted by survivor*

**I need to program the following:**

A company generates 61 percent of total sales. How much will the company generate if the company has $4.5 million in sales this year?

I am new at programming and I have no clue where to start:

amount_generated = total_sales * percentage;

Go read your book. Seriously. - 01-31-2003Spoonmaster
#include <iostream>

int main()

{

int gross = 4500000;

float percent_generated =0.61;

int total_profit;

for (gross = 4500000;total_profit=gross*percent_generated;gross *percent_generated)

{cout<<"Out putting total profit "<<total_profit<<endl;}

cin>>total_profit;

return 0;

}

Enjoy the infinite spam lol ...

PS: this equation works out even so no need for floats for gross or total_profit most money calculations need decimal places, - 01-31-2003Stan100Quote:

we won't do your homework but we will tell you this...

Quote:

God, that's easy. The equation is simple, ...

- 01-31-2003carrja99Quote:

*Originally posted by Spoonmaster*

**#include <iostream>**

int main()

{

int gross = 4500000;

float percent_generated =0.61;

int total_profit;

for (gross = 4500000;total_profit=gross*percent_generated;gross *percent_generated)

{cout<<"Out putting total profit "<<total_profit<<endl;}

cin>>total_profit;

return 0;

}

Enjoy the infinite spam lol ...

PS: this equation works out even so no need for floats for gross or total_profit most money calculations need decimal places,

What a retard.