Lab Manual 1 Flow Chart Repaired)
Lab Manual 1 Flow Chart Repaired)
Lab Manual 1 Flow Chart Repaired)
Fundamentals of Algorithms
CS – 201
Instructor
Ms. Saher Naqi
Submitted By
Mr. Muhammad. Irfan Arshad
Roll Number: 1387
BS – CS (3rd Semester)
START
Enter Roll #
& Name
Enter a Subject
Obtained Marks
STOP
Problem Statement 2:
50 students of a class appear in the problem 1. Draw a
flowchart for the algorithm to calculate and print the percentage marks obtained by
each student along with his roll number.
START
Enter a Roll#,
Name &marks
Loop 50 times
Display a
Percentages Along
With Roll# & Name
STOP
Problem Statement 3:
Draw a flow chart of the logical steps needed to produce
a printed listing of all students over the age of 20 in a class. The input records
contain the name and age of the students. Assume an initial value of 99 for the age
field.
START
Enter a Name
& age
If
Yes
age >20
Process on data
Display name
&age
STOP
Problem Statement 4:
Draw a flowchart of the logical steps needed to print the
name and age of the oldest and the youngest student in a class. The input records
contain the name and age of the students.
START
Enter a Name
& age
Check which
Youngest student is Oldest
young which
is old
STOP
Problem Statement 5:
A set of examination papers which have been graded with
scores from 0 to 100 is to be searched to find how many of them are above 90. The
total is to be printed.
START
Enter scores
(0-100)
Yes If Loop
scores
>90
No
Add total marks
Display total
marks
STOP
1.Input
2.Output
3.Definiteness
4.Effectiveness
5.Termination
Therefore, an algorithm can be defined as a sequence of definite and effective instructions, which
terminates with the production of correct output from the given input.