76.6k views
4 votes
___ is an example of a function prototype.

A) float roi(int, double);
B) printf("%f", roi(3, amt));
C) roi(3, amt);
D) float roi( int yrs, double rate)

User Woyaru
by
5.3k points

1 Answer

5 votes

Answer:

A

Step-by-step explanation:

B is a print statement.

C is a function invocation

D is a function declaration

A prototype is actually quite close to a declaration. The semi-colon at the end shows that no implementation will follow. Adding parameter names is allowed but would only be helpful for better understanding.

User Kevin Sitze
by
5.6k points