आज इस पोस्ट में हम सी लैंग्वेज का उपयोग करते हुए Simple Interest और Compound Interest निकलने के लिए एक प्रोग्राम बनाएंगे | मगर इससे पहले हम ये जान लेते है की Simple Interest और Compound Interest क्या है तथा ऐसे कैसे निकलते है फिर यही काम के लिए हम C Language में एक program बनायेगे |
Introduction to simple interest and compound interest
Simple Interest और Compound Interest आपके द्दारा लिए गए लोन का ब्याज निकालने का एक तरीका है | Simple Interest की गणना मूल राशि (Principle rate) पर की जाती है, Simple Interest निकालने के लिए इस formula का उपयोग किया जाता है
S.I = (P * R * T) / 100 जहाँ P = Principal , R = Rate and T = Time है
चक्रवृद्धि ब्याज (compound interest) की गणना मूल राशि और उस ब्याज पर की जाती है | compound interest निकालने के लिए इस formula का उपयोग किया जाता है
CI = P(1 + r / n)nt जहाँ P = Principal, R = Rate, n = number of compounding periods per unit and T = Time है |
C Program to Calculate the Simple interest
Algorithm -:
- Program start.
- Declaration of variable with their data type, like :- int P, R, T; float I;
- Input the value in variable
- Arithmetic operator used to perform SI=(p*r*t)/100;
- Printf( ) called to print value of variable
- Program end.
Flowchart -:

Program For Simple interest
#include<stdio.h>
#include<conio.h>
void main()
{
int p,r,t;
float i;
printf("Enter the Principal, Rate and Time\n");
scanf("%d %d %d",&p,&r,&t);
i=p*r*t/100; /*Formula for calculating simple interest*/
printf("simple interest is : %f",i);
getch();
}
Output -:
Enter the Principal, Rate and Time
5500
5
8
simple interest is : 2200.000000
C Program to Calculate the Simple interest
#include<stdio.h>
int main()
{
float p,r,t,CI;
printf("Enter Principle, rate and time\n");
scanf("%f%f%f",&p,&r,&t);
CI = p*pow((1+r/100),t); /*Formula for calculating Compound Interest*/
printf("Compound interest is : %f\n", CI);
return 0;
}
Output -:
Enter Principle, rate and time
5500
5
8
Compound interest is : 8126.004883
C Programming Examples
- C Program to Find the Average of Three Numbers
- C Program To Find The Largest Numbers Using Ternary Operator
- C Program to Check Leap Year