Annual Percentage Rate (APR) for a loan in Slovakia (RPMN)
Budget: $30 – $250 USD
We need to compute Annual Percentage Rate for a given loan according to Slovakia's law.
Right now, the loan is a so called pay-day loan, with only one instalment.
Standard APR for one instalment is computed as follows:
function aprRate(principal: number, fee: number, days: number): number {
const rate = Math.pow(principal / (principal + fee), -(365 / days))
return (rate - 1) * 100
}
In Slovakia, however, the computation is different - see the attached law.
Please read the law carefully and implement such a function (in any programming language).
Right now, the loan is a so called pay-day loan, with only one instalment.
Standard APR for one instalment is computed as follows:
function aprRate(principal: number, fee: number, days: number): number {
const rate = Math.pow(principal / (principal + fee), -(365 / days))
return (rate - 1) * 100
}
In Slovakia, however, the computation is different - see the attached law.
Please read the law carefully and implement such a function (in any programming language).
Related categories:
Slovakian Translator