What is the output of the following function call, given the function definition below?

cout << repeater (3, 7); // function call

repeater (int a, int b) // function definition
{
int num = 2;
for (int c = a, c < b, c++)
num += c;
return num;
}

a) 2
b) 10
c) 14
d) 20

d) 20

Computer Science & Information Technology

You might also like to view...

Which of the following is TRUE about margins in Word 2016?

A) Margins are only on the left and right edge of the paper. B) Margins are only at the top and bottom edge of the paper. C) The default top and bottom margins are 1". D) The default left and right margins are 1.25".

Computer Science & Information Technology

Of the four 2D collision types, which one offers the most flexibility, but at a cost to performance?

What will be an ideal response?

Computer Science & Information Technology