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

How were Japanese-Americans treated during World War II?
How were Japanese-Americans treated during World War II?
What should you ask yourself when analyzing word choice?
What do you make when you hit a rock with a hammer
The first meal eaten on the moon by astronauts Neil Armstrong and Buzz Aldren was a roasted turkey dinner with all the trimmings. True or False?
What is bigger 2/5 or 2/8
Which of the following statements is true about the Emily Dickinson poem 'Because I Could Not Stop For Death?' A. It portrays death as something not to be
Which best describes Jefferson’s response to the handling of the Whiskey Rebellion?
In "Beethoven's Moonlight Sonata," which line is an example of a detail the author added for dramatic interest? a. "Beethoven looked at me." b. "We can scarcel
Evidence that is based on personal observation is considered __________. inferential statistical anecdotal descriptive