Q:

Write a C Program to calculate simple interest

0

Write a C Program to calculate simple interest. Here’s simple Program to calculate simple interest in C Programming Language.

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

Write a C Program to calculate simple interest. Here’s simple Program to calculate simple interest in C Programming Language.

SOURCE CODE : :

/*  C Program to calculate simple interest  */

#include<stdio.h>
#include<conio.h>

int main()
{
  float principal,rate,time;
  float simpleInterest;
  printf("Enter the principal amount :: ");
  scanf("%f",&principal);
  printf("\nEnter the rate of interest :: ");
  scanf("%f",&rate);
  printf("\nEnter the time duration :: ");
  scanf("%f",&time);
  simpleInterest=(principal*rate*time)/100;
  printf("\nThe simple interest is %f \n",simpleInterest);

  return 0;
}

OUTPUT : :

 

Enter the principal amount :: 385000

Enter the rate of interest :: 13.89

Enter the time duration :: 4

The simple interest is 213906.000000

Above is the source code for C Program to calculate a simple interest which is successfully compiled and run on Windows System.The Output of the program is shown above .

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

C Basic Solved Programs – C Programming

This question belongs to these collections

Similar questions


need a help?


find thousands of online teachers now
C program to convert Total days to year, month and... >>
<< Write a C Program to Print Hello World Program...