Assignment No. 1
CS201P Assignment 1 Solution
|Total Marks: 20
Dec 16, 2021
Please read the following instructions carefully before submitting assignment:
It should be clear that your assignment will not get any credit if:
Assignment is submitted after due date.
Submitted assignment does not open or file is corrupt.
Assignment is copied (From internet/students).
Recommended tool to develop Assignment
– Dev C++
To enable students to understand and practice the concepts of:
Assignment Submission Instructions
You have to submit only.cpp file on the assignments interface of CS201P from your LMS account. Assignment submitted in any other format will not be accepted and will be scaled with zero marks.
For any query related to assignment, please contact us at email@example.com.
Virtual Univeristy of Pakistan is a well renowned and one of the top universities of Pakistan. Recently the university has started the admission process of BS level Students for Fall 2021 Semester. During the admission period the university receives a lot of applicant’s requests for admission. For finding out which students are eligible or meet the criteria for admission. The university has decided to conduct an Entry test.
Following are some of the details of the students who have given the entry test and scored respectable marks:
Being a C++ developer, you are required to write a program which will find out the following information from the above data:
1) Aggregate Percentage for each student
To find out the aggregate percentage of each student the program will calculate the marks in the following ratio:
Matriculation (SSC) – 10%
Intermediate (HSSC/F. Sc) – 40%
Entrance Test – 50%
Step – I:
SSC Marks Agg: Marks obtained in SSC /1050 x 1050 x 10%
Step – II:
HSSC Marks Agg: Marks obtained in HSSC /1100 x 1100 x 40%
Step – III:
Entry Test Agg: Marks obtained in Entrance Test / 1100 x 1100 x 50 %
Step – IV:
Aggregate Marks: SSC Marks Agg + HSSC Marks Agg + Entry Test Agg
Step – V:
Aggregate Percentage Aggregate Marks/1100 x 100
Important Instruction: You need to calculate all the above steps in the main function.
2) Maximum Aggregate percentage among the students
To fund out the maximum aggregate percentage among the students. You need to write a function maxAggregate() which will receives three arguments from the main function and will return the maximum aggregate percentage.
3) Count of students which are eligible for admission.
To find out the count of eligible students for admission. You need to write a function eligibleStudentCount() which will received three arguments from the main function and return the count.
Important Instruction: Eligibility criteria for admission is that student aggregate percentage should be greater or equal to 90.
4) Sum of Aggregate marks for all students.
To find out the sum of aggregate marks for all students. You need to write a function named aggSum() which will receives three arguments from the main function and return its sum. To calculate the sum you need to use the looping structure (while, do-while, for loop). You can use any one of them
Note: For consistency of the assignment, you are required to use only the source data given above. In case of varied data, marks will be deducted.