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
Inessa [10]
3 years ago
7

Complete function PrintPopcornTime(), with int parameter bagOunces, and void return type. If bagOunces is less than 3, print "To

o small". If greater than 10, print "Too large". Otherwise, compute and print 6 * bagOunces followed by " seconds". End with a newline. Example output for ounces = 7:
Engineering
1 answer:
weqwewe [10]3 years ago
8 0

Answer:

#include <iostream>

using namespace std;

void PrintPopcornTime(int bagOunces) {

if(bagOunces < 3){

 cout << "Too small";

 cout << endl;

}

else if(bagOunces > 10){

 cout << "Too large";

 cout << endl;

}

else{

 cout << (6 * bagOunces) << " seconds" << endl;

}

}

int main() {

  PrintPopcornTime(7);

  return 0;

}

Explanation:

Using C++ to write the program. In line 1 we define the header "#include <iostream>"  that defines the standard input/output stream objects. In line 2 "using namespace std" gives me the ability to use classes or functions, From lines 5 to 17 we define the function "PrintPopcornTime(), with int parameter bagOunces" Line 19 we can then call the function using 7 as the argument "PrintPopcornTime(7);" to get the expected output.

You might be interested in
The alternator must be operated with the battery disconnected or with the terminals at the back of the alternator
QveST [7]

Answer:

true

Explanation:

4 0
3 years ago
Read 2 more answers
12.28 LAB: Output values in a list below a user defined amount - functions Write a program that first gets a list of integers fr
Anastaziya [24]

Answer:

def output_ints_less_than_or_equal_to_threshold(user_values, upper_threshold):

   for value in user_values:

       if value < upper_threshold:

           print(value)  

def get_user_values():

   n = int(input())

   lst = []

   for i in range(n):

       lst.append(int(input()))

   return lst  

if __name__ == '__main__':

   userValues = get_user_values()

   upperThreshold = int(input())

   output_ints_less_than_or_equal_to_threshold(userValues, upperThreshold)

8 0
3 years ago
Answer ppeeeeeaaaalll
Bad White [126]

Answer:

what

Explanation:

is this an exam or an test or what is it

3 0
3 years ago
Are front-end engineers starting to decline in China?
laiz [17]

Yes. They are declining in China. Very fast

7 0
3 years ago
The part of a circuit that carries the flow of electrons is referred to as the?
Oksanka [162]

Answer:

  Conductor

Explanation:

Current is carried by a conductor.

__

The purpose of a dielectric and/or insulator is to prevent current flow. An electrostatic field may set up the conditions for current flow, but it carries no current itself.

7 0
3 years ago
Other questions:
  • The popularity of orange juice, especially as a breakfast drink, makes it an important factor in the economy of orange-growing r
    14·1 answer
  • A high-voltage direct-current (dc) transmission line between Celilo, Oregon and Sylmar, California is 845 mi in length. The line
    15·1 answer
  • How does a car batteray NOT die?
    13·1 answer
  • 11 Notează, în caiet, trăsăturile personajelor ce se pot
    13·1 answer
  • An electric field is expressed in rectangular coordinates by E = 6x2ax + 6y ay +4az V/m.Find:a) VMN if point M and N are specifi
    9·1 answer
  • Given two alphabet strings str1 and str2. You can change the characters in str1 to any alphabet characters in order to transform
    8·1 answer
  • ... is an actual sequence of interactions (i.e., an instance) describing one specific situation; a ... is a general sequence of
    9·1 answer
  • Four subjects civil engineers need to study​
    12·1 answer
  • Explain the use of a vacuum gauge.
    15·1 answer
  • Periodic lubrication and oil changes according to manufacturer’s recommendations extend the life of your vehicle, and allow you
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!