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
Nikolay [14]
4 years ago
14

Write the definition of a function printLarger, which has two int parameters and returns nothing. The function prints the larger

value of the two parameters to standard output on a single line by itself.
Engineering
1 answer:
vredina [299]4 years ago
7 0

Answer:

  1. #include <iostream>
  2. using namespace std;
  3. void printLarger(int a, int b){
  4.    
  5.    if(a > b){
  6.        cout<<a;
  7.    }else{
  8.        cout<<b;
  9.    }
  10. }
  11. int main()
  12. {
  13.    printLarger(4, 5);
  14.    return 0;
  15. }

Explanation:

The solution code is written in C++.

Firstly define a function printLarger that has two parameters, a and b with both of them are integer type (Line 5). In the function, create an if condition to check if a bigger than b, print a to terminal (Line 7-8). Otherwise print b (Line 9-10).

In the main program, test the function by passing 4 and 5 as arguments (Line 16) and we shall get 5 printed.  

You might be interested in
As the junior engineer at the Mesabi Range Hydraulic Engineering Company located in Ely, Minnesota, you have been tasked with de
katen-ka-za [31]

yes it will

Explanation:

5 0
4 years ago
Select the correct answer. Sean is a recent engineering graduate who has joined a new company. Read the profiles of his colleagu
PSYCHO15rus [73]

Answer:

giving advertising to the governor with the state

4 0
3 years ago
Consider a piston-cylinder device with a piston surface area of 0.1 m^2 initially filled with 0.05 m^3 of saturated water vapor
miv72 [106K]

The friction force f = 10000 N

The heat transfer Q = 1.7936 KJ

<u>Explanation:</u>

Given data:

Surface area of Piston = 1 m^{2}

Volume of saturated water vapor = 100 K Pa

Steam volume = 0.05 m^{3}

Using the table of steam at 100 K pa

Steam density = 0.590 Kg/m^{3}

Specific heat C_{p} = 2.0267 KJ/Kg K

Mass of vapor = S × V

m = 0.590 × 0.05

m = 0.0295 Kg

Solution:

a) The friction force is calculated

Friction force = In the given situation, the force need to stuck the piston.

= pressure inside the cylinder × piston area

= 100 × 10^{3}  × 0.1

f = 10000 N

b)  To calculate heat transfer.

Heat transfer = Heat needs drop temperatures 30°C.

Q=m c_{p} \ DT

Q = 0.0295 × 2.0267 × 10^{3} × 30

Q = 1.7936 KJ

3 0
4 years ago
A. 50
Mademuasel [1]

Answer:ahahahahahah

Explanation:boyboy

6 0
3 years ago
When implementing a safety and health program, management leadership does not need employee participation a True b) False Effect
sladkih [1.3K]

Answer: I have answered the questions in rephrased sentences as below;

When implementing a safety and health program, management leadership need employee participation. Effective management of worker safety and health programs has improved employee productivity and morale in the workplace.

Nearly a third of all serious occupational injuries and illnesses stem from overexertion of repetitive motion.

Training is a way for employers to provide tools to enable employees to protect themselves and others from injuries.

Under OSHA, employees are protected from discrimination when reporting a work-related injury, illness, or fatality.

Explanation: All personnel including management & employees must be directly involved when workplace HSE policies are being made & reviewed. This is because everyone in the work environment is impacted one way or the other when incidents occur.

Training & Reporting are key responsibilities of managers, employers & supervisors, so it is mandatory to be done without discrimination so as to foster employees happiness which ultimately lead to zero incidents & increased productivity & profit.

3 0
3 years ago
Other questions:
  • 4. The friction point is the point
    12·1 answer
  • Need answers for these please ​
    15·1 answer
  • Looking for new information is one reason you should do research for a speech.
    15·2 answers
  • The engine of a 1500-kg automobile has a power rat- ing of 75 kW. Determine the time required to accelerate this car from rest t
    10·1 answer
  • Water at 80°F and 30 psia is heated in a chamber by mixing it with saturated water vapor at 30 psia. If both streams enter the m
    13·1 answer
  • A ten story hospital has to constructed with the footprint of 45,000 ft^2. Subsurface soil consist of soft clay layer of 10 ft.
    15·1 answer
  • g A motor driving a 1000-W water pump has a power factor of 0.80 lagging; a second motor driving a 600-W water pump has a power
    15·1 answer
  • For Figure Below, if the elevation of the benchmark A is 25.00 m above MSL:
    14·1 answer
  • Shane's 100-watt radio draws 7 amps of current on a 120-volt circuit. What is the resistance in the radio?
    8·1 answer
  • On some engines after torquing cylinder head fasteners you must
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!