1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Gennadij [26K]
3 years ago
12

Energy Drink Consumption A soft drink company recently surveyed 16,500 of its customers and found that approximately 15 percent

of those surveyed purchase one or more energy drinks per week. Of those customers who purchase energy drinks, approximately 58 percent of them prefer citrus-flavored energy drinks. Write a program that displays the following: The approximate number of customers in the survey who purchase one or more energy drinks per week The approximate number of customers in the survey who prefer citrus-flavored energy drinks.
Computers and Technology
1 answer:
slamgirl [31]3 years ago
5 0

Answer:

Follows are the code to this question:

#include <iostream>//header file

using namespace std;

int main()//defining a main method

{

int customer= 16508;//defining an integer variable

int E_drink, C_drink;//defining an integer variable

double buy_Energy_drink,buy_cold_drink;//defining a double variable

buy_Energy_drink= 0.15;//use double variable to assign value

buy_cold_drink= buy_Energy_drink *0.58;//use double variable to calculate value

E_drink = customer*buy_Energy_drink;//calculating value of E_drink

C_drink= customer*buy_cold_drink;//calculating value of E_drink

cout<<"\t\t\t -:Energy Drink Consumption:-"<<endl;//print message

cout<<"According to A soft drink company surveyed 16,500 of its customers."<<endl;//print message

cout<<E_drink <<" customer purchase one or more energy drinks per week."<<endl;//print message with value

cout<<C_drink <<" customer who prefer citrus-flavored energy drinks."<<endl;//print message with value

return 0;

}

Output:

Please find the attached file.

Explanation:

In this code, three integer variable "customer, E_drink, and C_drink" is defined, in which the first variable is used to hold a value, and the next two variables are used for calculating the value.

In the next step, two double variables "buy_Energy_drink, buy_cold_drink" is defined that calculate the given percentage value and passed into the integer variable to calculate the value and print the value with the given message.

You might be interested in
What does UDP stand for?
sleet_krkn [62]
User Datagram Protocol
3 0
3 years ago
Read 2 more answers
Sam's take-home pay is $743. His deductions are $25 for OASDI, $5 for Medicare, and $27 for income tax. What is his gross pay? A
Katarina [22]

<u>Answer:</u>

A. $686.00

<u>Reasoning:</u>

25+5+27=57 So the total amount of the deductions is $57

Subtract 57 from 743

743 - 57 = 686

So he is left with 686

5 0
3 years ago
Which program will have the output shown below?
Nutka1998 [239]

Answer: Python

Explanation: All I know is that the programming language is Python.

8 0
2 years ago
Read 2 more answers
Describe types of hardware used for output​
sashaice [31]
A computer output device is used to extract information from a computer. There are visual, audio, print and data output devices. Different types of specific hardware include monitors, speakers and headphones, printers and external hard drives.
3 0
3 years ago
In the state of Florida your first conviction for DUI can result in your vehicle being impounded for:
Gwar [14]
The Answer is 10 Days
8 0
3 years ago
Read 2 more answers
Other questions:
  • A certain computer has a 4meg address space. how many bits wide is this computer's address bus?
    10·1 answer
  • PLZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZZ HELP!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    11·2 answers
  • When a hardware or software interrupt occurs, the CPU calls________
    14·1 answer
  • Write a program that prints the numbers 1 to 4 on the sameline with each pair of adjacent numbers separated by a single space(1
    5·1 answer
  • For each of the following cases, select the type of NoSQL DBMS that would fit best the needs of the situation. a. The database h
    10·1 answer
  • Write a for loop that computes the following sum: 5+10+15+20+...+485+490+495+500. The sum should be placed in a variable sum tha
    7·1 answer
  • TRUE OR FALSE - SQL language is used to query data in a Relational Database?
    5·1 answer
  • ____ returns the maximum number of elements that can be inserted into the vector container vecCont without reallocation.
    9·1 answer
  • How did the tropica cyclone impact the environment​
    14·1 answer
  • How does the dns help the world wide web scale so that billions of users can access billions of web pages?.
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!