Answer:
printf("%f", roi(3, amt));
Explanation:
To call the function, we have to put the function name without return type and if the function have parameter then we have to pass the parameter without data type as well.
Let discuss the options:
Option A: float roi(int, double);
it is not a calling, it is used to declare the function. In calling, return type of the function like float and data type of the parameter does not pass like int, double.
Option B: printf("%f", roi(3, amt));
print is used to display the result, inside the print it call the function. It is correct way to call the function.
Option C: float roi( int yrs, double rate);
it is not a calling, it is used to declare the function. In calling, return type of the function like float and data type of the parameter does not pass like int, double.
Option D: float roi( int yrs, double rate)
Same reason as option C.
Therefore, the option B is correct option.