HELP!

I'm having some trouble with this problem. Maybe it's the way it is worded, but I can't seem to figure out the way to input the data to make it come out right. I'm BRAND new to programming and in intro to CS. The problem is:

1. Write a program that asks the user for a value that represents the total sales of Company X. Store that value into a variable. Assume the following: Company X’s East division generates 35% of sales, the West division 22%, the North division 29.6% and the South division generates 13.4% of total sales. Store these values in 4 named constants near top of your program. Compute the 4 divisional sales and place these values into 4 variables that you create. Display your results in a tasteful fashion. If your output display looks funky, consider reading ahead to page 118 and controlling things like decimal places.


What I have in place, and don't laugh, is:

//Joseph Nolan CS1613 1/30/2015

#include <iostream>
using namespace std;

int main ()
{

//declare and initialize variables

const double eastDivision = 0.35;
const double westDivision = 0.22;
const double northDivision = 0.296;
const double southDivision = 0.134;

double nolanInterprise = 0.0;


//input data
cout << " Enter a value for the Nolan Enterprise: ";
cin >> nolanInterprise;


//process data
;

//output section
cout << "\nYou entered " << eastDivision << ", " << westDivision << ", " << endl;
cout << northDivision << "and " << southDivision <<endl;
cout << endl;

system("pause");
return 0;

}

Am I even remotely headed in the right direction?

Thanks!
Up to input is ok. Then you should:
Compute the 4 divisional sales and place these values into 4 variables that you create.

Four more variables. Their values you should compute and then show.


PS. Please use code tags: http://www.cplusplus.com/articles/jEywvCM9/
Last edited on
Topic archived. No new replies allowed.