Introduction
  • In this blog, I am going to explain how to find the compound interest in C programming.
Software Requirements
  • Turbo C++ or C.
Programming
  1. #include < stdio.h >
  2. #include < math.h > int main()
  3. {
  4. float amount, rate, time, CI;
  5. printf("Enter principle (amount): ");
  6. scanf("%f", & amount);
  7. printf("Enter time: ");
  8. scanf("%f", & time);
  9. printf("Enter rate: ");
  10. scanf("%f", & rate);
  11. CI = amount * (pow((1 + rate / 100), time) - 1);
  12. printf("Compound Interest = %f", CI);
  13. return 0;
  14. }
Explanation
  • In the programming, given above, the compound interest can be calculated by a simple formula and it can be in a simple manner.

    programming
Output

Output

Conclusion
  • Thus, the program can be executed and printed successfully.