Question
// This program demonstrates the use of characters and strings // bos #include #include using namespace std; // Declaration of constants const string FAVORITESODA =
// This program demonstrates the use of characters and strings
// bos
#include
// Declaration of constants const string FAVORITESODA = "Dr. Dolittle"; // use double quotes for strings const char BESTRATING = 'A'; // use single quotes for characters
int main()
{
char rating; // 2nd highest product rating string favoriteSnack; // most preferred snack int numberOfPeople; // the number of people in the survey int topChoiceTotal; // the number of people who prefer the top choice // Fill in the code to do the following: // Assign the value of "crackers" to favoriteSnack // Assign a grade of 'B' to rating // Assign the number 250 to the numberOfPeople // Assign the number 148 to the topChoiceTotal
// Fill in the blanks of the following: cout << "The preferred soda is " <<____________<< endl; cout << "The preferred snack is " <<___________<< endl; cout << "Out of " <<_____________ << " people " <<____________ << " chose these items!" << endl; cout << "Each of these products were given a rating of " <<__________; cout << " from our expert tasters" << endl; cout << "The other products were rated no higher than a " << rating << endl;
return 0;
}
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started