a10v2..cpp

# a10v2..cpp - /courseID:CIS165-006HY/name Marlen...

• Homework Help
• 3

This preview shows page 1 - 3 out of 3 pages.

//courseID:CIS165-006HY //name: Marlen Herrera //Prof. Wang //Assignment #10 //Due by 11/21/2017 /* steps 1.Input: a. store1 b. store2 c. store3 d. store4 e. store5 2.Processing: a. store1/100 b. store2/100 c. store3/100 d. store4/100 e. store5/100 3.Output: a."This program compares the daily sales for five stores." b."Enter todays sales for store 1: " c."Enter todays sales for store 2: " d."Enter todays sales for store 3: " e."Enter todays sales for store 4: " f."Enter todays sales for store 5: " g."Sales cannot be negative. Please input another value: " */ #include <iostream> using namespace std; int main() { int store1 = 0, store2 = 0, store3 = 0, store4 = 0, store5 = 0; cout << "This program compares the daily sales for five stores.\n"; cout << "Enter todays sales for store 1: "; cin >> store1; while (store1 <= 0) { cout << "Sales cannot be negative. Please input another value: "; cin >> store1; } cout << "Enter todays sales for store 2: "; cin >> store2; while (store2 <= 0) { cout << "Sales cannot be negative. Please input another value: "; cin >> store2; } cout << "Enter todays sales for store 3: ";

Subscribe to view the full document.

cin >> store3;
• Spring '15
• Wang, Carriage return, \$100, #include, //Prof. Wang, Marlen Herrera

{[ snackBarMessage ]}

###### "Before using Course Hero my grade was at 78%. By the end of the semester my grade was at 90%. I could not have done it without all the class material I found."
— Christopher R., University of Rhode Island '15, Course Hero Intern

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern