*C program to calculate EMI or EMI Calculator*

**Write a C program to calculate EMI or EMI Calculator.**This program is take Principal, Rate and Time to calculate EMI to produce the desired output .

**What is EMI (Equated Monthly Installment) ?**

**What is EMI (Equated Monthly Installment) ?**

- Equated Monthly Installment – EMI for short – is the amount payable every month to the bank or any other financial institution until the loan amount is fully paid off.

- It consists of the interest on loan as well as part of the principal amount to be repaid. The sum of principal amount and interest is divided by the tenure, i.e., number of months, in which the loan has to be repaid. This amount has to be paid monthly.

- The interest component of the EMI would be larger during the initial months and gradually reduce with each payment. The exact percentage allocated towards payment of the principal depends on the interest rate.

- Even though your monthly EMI payment won’t change, the proportion of principal and interest components will change with time. With each successive payment, you’ll pay more towards the principal and less in interest.

* Formula to calculate EMI *: :

where,

**E**is EMI

**P**is Principal Loan Amount

**r**is rate of interest calculated on monthly basis.

**n**is loan term / tenure / duration in number of months

Below is the source code of the **C program to calculate EMI or EMI Calculator ** which is successfully compiled and run on the windows system.The Output of the program is shown below.

*SOURCE CODE : :*

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
#include <stdio.h> #include <math.h> int main() { float principal, rate, time, emi; printf("Enter principal: "); scanf("%f",&principal); printf("Enter rate: "); scanf("%f",&rate); printf("Enter time in year: "); scanf("%f",&time); rate=rate/(12*100); /*one month interest*/ time=time*12; /*one month period*/ emi= (principal*rate*pow(1+rate,time))/(pow(1+rate,time)-1); printf("Monthly EMI is= %f\n",emi); return 0; } |

**Output : :**

**Output : :**

1 2 3 4 |
Enter principal: 380000 Enter rate: 13.69 Enter time in year: 4 Monthly EMI is= 10325.068359 |