## Compound Interest Formula

Amount=P(1+r/100)^{t}

P=Principal Amount

r=Rate of Interest

t=Time Periods.

## Program to Find Compound Interest Using C Programming

```
#include<stdio.h>
#include<math.h>
int main()
{
int principal_amount,rate_of_interest,Interest_applied,time_periods;
printf("\n\n\tProgram to Find Compound Interest Using C Programming.");
printf("\n\tEnter Principal Amount.");
scanf("%d",&principal_amount);
printf("\n\tEnter Rate of Interest.");
scanf("%d",&rate_of_interest);
printf("\n\tEnter Time Periods.");
scanf("%d",&time_periods);
float compond_interest=principal_amount*pow((1+(rate_of_interest/100)),time_periods);
printf("\n\tCompound Interest is: %lf\n\n\n",compond_interest);
return 0;
}
```

### Output

Program to Find Compound Interest Using C Programming. Enter Principal Amount.2000 Enter Rate of Interest.2 Enter Time Periods.3 Compound Interest is: 2000.000000

### Code Explanation

First, ask the user to input Principal Amount, Rate of Interest, Time Period.

Store the input values to variables using `scanf()`

function.

In the program using the formula compound interest is calculated and stored in compound interest variable.

Print the output.