Can someone explain how to write this as an exponential value since i have NO clue at all?
monPayment=(loanAmt*(monIntRate)/(1-(1-monIntRate) and then right here is the exponent -noMonths)
How do I do it as an exponent for -noMonths? Something with Pow I know...but I cannot for the life of me figure it out!
pow(x, y) computes x to the y'th power.
Okay, so wait...I would write it like this?
pow( (loanAmt*(monIntRate)/(1-(1-monIntRate), -noMonths)
Is that right?
Why don't you just calculate the term and its exponent on one line and use that result for the full calculation on another line?
If a calculation is too complex for you, break it down. You could calculate the numerator on one line, then you could calculate the term with the exponent on another line, then you could calculate the full denominator on a third line, and then you could calculate the numerator over the denominator on a 4th line.
you forgot a ')' on the end there ;)
Yeah I see that now but that's because it was like that originally and I just copypasted it so I will not take the blame for this :(
Umm..yeah, the parenthesis were my fault. Looking at it again, I forgot one.
Anyway, does that (with an extra parenthesis) work for an exponent? I'm going to try it that way!
You guys rock!! :)
Make sure you include <cmath> when you're using pow().