A i think idk im trying to earn points
Answer: The function Stella can use to calculate the periodic payments of a loan is:
The Excel PMT function or NPER function.
Explanation: 1. The Excel PMT function is a financial function that returns the periodic payment for a loan.
2. The NPER function to figure out payments for a loan, given the loan amount, number of periods, and interest rate.
Answer:
int calculate_cost(int quantity) {
double cost = 0;
if (quantity <= 20)
cost = quantity * 23.45;
else if (quantity >= 21 && quantity <= 100)
cost = quantity * 21.11;
else if (quantity > 100)
cost = quantity * 18.75;
return cost;
}
Explanation:
Create a function called calculate_cost that takes one parameter, quantity
Initialize the cost as 0
Check the quantity using if else structure. Depending on the quantity passed, calculate the cost. For example, if the quantity is 10, the cost will be $234.5
Return the cost