### Overview:

Let us learn how to calculate simple interest in C programming language. Simple interest is basically a quick and easy calculation of the interest charged on a given principal amount. Before going to write the c program to Calculate Simple Interest, let's understand What is Interest?, What are the types of Interest?, and What is Simple Interest? Moreover, I will show How to calculate Simple Interest? and define P, R, and T in a simple interest formula. Furthermore, I will demonstrate the logic to calculate Simple Interest. After all, I will write a logic and C program to Calculate Simple Interest with output.

### Table of contents:

- What is Interest?
- What are the types of Interest?
- What is Simple Interest?
- How to calculate Simple Interest?
- What is Principal amount?
- What is rate of Interest?
- What do you mean by time in Simple Interest formula?
- Demonstration to calculate simple interest
- Logic to calculate simple interest
- C Program to Calculate Simple Interest with output
- Conclusion

### What is Interest?

Interest is the extra money that the borrower pays for using the lender’s money. When a person lends money to a borrower, the borrower usually has to pay an extra amount of money to the lender. This extra money is what we call the interest. In other words, If you deposit money in a bank, interest is the money that you earn, as a percentage of your deposit.

### What are the types of Interest?

There are three types of Interest as follows:

- Simple (Regular) Interest
- Accrued Interest
- Compound Interest

### What is Simple Interest?

Simple Interest (S.I.) is the method of calculating the interest amount for some principal amount of money. In other words, Simple Interest is the rate at which we lend or borrow money.

### How to calculate Simple Interest?

Simple interest formula calculated by following the Simple Interest formula:

*Simple Interest = (Principal Amount × Rate of Interest × Number of years) / 100 *

or

* SI = (P × R × T)/100 *

Where,

SI is the Simple Interest

P is the principal amount

T is the time period for which money is invested

R is the rate of interest

### What is the Principal amount?

It is a starting amount of money. In the context of borrowing, the principal is the initial size of a loan; it can also be the amount still owed on a loan.

### What is the rate of Interest?

The interest rate is the amount a lender charges for the use of assets expressed as a percentage of the principal. It is the interest rate per year.

### What do you mean by T in the Simple Interest formula?

T is the time period in which money is invested or borrowed.

### Demonstration to calculate simple interest

To calculate simple interest we will take the help of this formula:

You can understand it from the following example:

**Question: **Calculate the Simple Interest if the principal amount is Rs. 2000, the time period is 1 year and the rate is 10%.

**Solution: **According to the formula of simple interest we have,

S.I. = [(Principal (P) × Time (T) × Rate (r)) / 100]

So, from the above values,

S.I. = [(2000 × 1 × 10)] / 100 = 20000/100 =200

So, the simple interest at the end of 1 year will be Rs. 200.

### Logic to calculate simple interest

**Step 1:**Input principal amount in some variable say principle.**Step 2:**Input time in some variable say time.**Step 3:**Input rate in some variable say rate.**Step 4:**Find simple interest using the formula SI = (principle * time * rate) / 100.**Step 5:**Finally, print the resultant value of SI.

### C Program to Calculate Simple Interest

/** * C program to calculate simple interest */ #include int main() { float principal, time, rate, SI; /* Input principle, rate and time */ printf("Enter principal (amount): "); scanf("%f", &principle); printf("Enter time: "); scanf("%f", &time); printf("Enter rate: "); scanf("%f", &rate); /* Calculate simple interest */ SI = (principal * time * rate) / 100; /* Print the resultant value of SI */ printf("Simple Interest = %f", SI); return 0; }

**The output of the Program with code: **

When the above code is executed, it produces the following results:

Enter the principal amount: 12

Enter time: 2

Enter rate: 3

Simple Interest = 0.720000

**Conclusion:**

This C program allows the user to enter the Principal Amount, Rate of Interest, and the number of years. By using those values, this C Program will calculate the Simple Interest using the following formula: Simple Interest = (Principal Amount * Rate of Interest * Number of years) / 100.