[1/2] Calculation of Simple for 3 sets of PNR (using While loop)
The following program is used to calculate 3 Sets of values of P, N, R.
This is made possible using the While Loop.
#include<stdio.h>
main()
{
int p, n, count;
float r, si;
count = 1;
while (count <= 3)
{
printf ("\nEnter values of p, n and r");
scanf ("%d %d %f", &p, &n, &r);
si = p*n*r / 100;
printf ("Simple Interest = Rs. %f", si);
count = count + 1;
}
}
You can download the File at:
Download File.
This is made possible using the While Loop.
#include<stdio.h>
main()
{
int p, n, count;
float r, si;
count = 1;
while (count <= 3)
{
printf ("\nEnter values of p, n and r");
scanf ("%d %d %f", &p, &n, &r);
si = p*n*r / 100;
printf ("Simple Interest = Rs. %f", si);
count = count + 1;
}
}
You can download the File at:
Download File.
Comments