Professional Documents
Culture Documents
Lab File For PPS
Lab File For PPS
Lab File For PPS
Bachelor of Technology
In
Computer Science & Engineering
Submitted to : Submitted by :
Ms. Deepshiksha Sharma Harpal Singh Lodhi
(Assistant Professor) B.Tech CSE (1st Sem)
Department of CSE Section A G-1
INDEX
S.N0. Activity/Programs Page No. Date Signature
PROGRAM NO. 1
Write a program that accepts the marks of 5 subjects and find the sum
and percentage marks obtained by the students.
#include<stdio.h>
int main()
{
int s1,s2,s3,s4,s5,sum;
float perc;
//Accept marks for 5 subjects max marks 100 for each subject
printf("Enter marks for 5 subjects: \n");
scanf("%d %d %d %d %d", &s1,&s2,&s3,&s4,&s5);
return 0;
}
Output
PROGRAM NO. 2
Write a program that calculate the Simple Interest and Compound
Interest. The Principle, Amount, Rate of interest and Time are entered
through the keyboard.
#include<stdio.h>
#include<math.h>
int main()
{
float p,r,t,si,ci;
int n;
#include<stdio.h>
int main()
{
float r,ar,cir;
float pi=3.141;
//Accept input for Circle
printf("Enter the radius of the circle:");
scanf("%f",&r);
return 0;
}
Output