allb5073 allb5073
  • 04-07-2019
  • Computers and Technology
contestada

What does the following function return? double compute speed(double distance); A. a double B. distance C. an integer D. nothing

Respuesta :

PhantomWisdom PhantomWisdom
  • 11-07-2019

Answer:

A. a double

Explanation:

The syntax of the function is:

type name( argument_1, argument_1,...... )

{  

    statement;

}

In the above syntax "type" define the return type of the function.

for example:

int count( int n);

so, it return the integer. Because the return type is 'int'.

In the question,

double compute speed(double distance);

Here, the return type is double. So, it return double.

Answer Link

Otras preguntas

If body fat has a density of 0.93 g/mL and 3.7 L of fat is removed, how many pounds of fat were removed from the patient?
Can someone explain to me how to do this
What reminded michael palin of a slice of melon?
I need help is it A B C or D
In 24 years, Travis will be 3 times his present age. How old is he now? Given equation with x being his current age in years: ( ) = 3x
British colonial servant in the 19th century wins his ideal job of serving in India. He thinks he will bring culture and enlightenment to the people in the cou
30 divide by 6 equal what
which of the following must be true of the structures of axons and muscle cells in order for nerve impulses to stimulate muscle contractions
The first part of the LRAS Curve conveys an economic recession. What does this mean? A. The economy is inefficient and has excess capacity for production. B.
Read the statement. He is a celebrity, but he cannot help your family. Is this argument sound or unsound? unsound sound