In this tutorial, we are going to write a C Program to find the simple interest in C Programming with practical program code and step-by-step full complete explanation.

C Program to find the simple Interest


C Program to find the simple Interest.

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

void main()
{
	int p, r, t, si;

	clrscr();

	printf("Enter principle, Rate of interest & time to find simple interest: ");

	scanf("%d%d%d",&p,&r,&t);

	si = (p*r*t)/100;

	printf("Simple intrest = %d", si);

	getch();
}


Output

Enter principle, rate of interest & time to find simple interest: 500
5
2
Simple interest = 50


In this Above C Program First, we include all the necessary header files that we need to use in our program. and we define the main function. after that, we define four integer variables p, r, t, si, and use the clrscr() function to clear the output screen.

After that, we use the printf() function to print the message on the output screen. and then scanf() function to take input and store them in a variable. after that we use the (p*r*t)/100 formula to find the simple interest of the given input values and then using the printf() function we print the value on the screen.