0% found this document useful (0 votes)
29 views4 pages

Fall 2024 - CS441 - 1

DSFDS
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
29 views4 pages

Fall 2024 - CS441 - 1

DSFDS
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

Virtual University of Pakistan SEMESTER FALL 2024

CS441 – Big Data Concepts


Assignment No.1 (Graded)

Maximum Marks: 20
Instructions Due Date: 8 November
2024

The purpose of this assignment is to give you hands-on practice. It is expected that
students will solve the assignment themselves. The following rules will apply during the
evaluation of the assignment.

● Cheating from any source will result in zero marks in


the assignment.
● The submitted assignment does NOT open or the file is corrupted.
● No assignment after the due date will be accepted.
● Students can submit HTML, Images & Plain text only in this inline Mode.
You may also insert an image file/table.
● (DOC/pdf File uploading option will not be available) in inline
assignment submission.
Uploading Assignment Instruction
Follow the given instructions to submit the inline assignment.

 Students can write their code in Python interpreter either by installing it on your
system or using the following online compiler.
https://www.programiz.com/python-programming/online-compiler/

 Students can copy/paste their Python Code into the submission interface as shown
below.
Virtual University of Pakistan SEMESTER FALL 2024

 Students can insert the snapshot images in the following formats.

 Snapshot Images can be inserted using the following highlighted option in the interface.

Lectures Covered
This assignment covers contents covered in Weeks 1-3.

Objective & Learning Outcome


This assignment task will test your knowledge of Python fundamentals such as loops,
conditional statements, functions, and string concatenation, while using randomized data to
ensure unique outputs.
After completing the assignment, the student will be able to implement and execute Loops,
Conditional Statements, Functions and how to execute code in Python language.

Question No. 1 (20 Marks)

Let suppose, you are a software developer tasked with building a Student Performance
Evaluation System for a university. Your job is to write a Python program that will randomly
generate student IDs, assign their marks in three subjects, and calculate their total marks,
average score, and final grade. The system should provide a clear and formatted report for
each student, displaying their details along with the calculated grade based on their
performance.

The university operator will input the number of students, and your system will:

 Randomly generate a unique Student ID for each student (in the format:
BC145789234).
 Assign random marks to each student in three subjects.
 Calculate the total marks, average score, and assign a grade based on the average.
 Print a detailed performance report for each student that includes their Student
ID, total marks, average score, and final grade.
Virtual University of Pakistan SEMESTER FALL 2024

Assignment Requirements:

1. Student Data Generation:

 Write a function generate_student_id() that generates a unique Student ID in the


format: BC followed by 9 random digits (e.g., BC145789234).
 Write a function generate_student_data(n) that creates random marks for 3
subjects (each between 0 and 100) for each student. The number of students
n should be input by the user.

2. Grade Calculation:

 Write a function calculate_grade() that takes a student’s total marks and calculates
their average score. Assign a grade based on the following scale:
o A: Average >= 85
o B: 70 <= Average < 85
o C: 50 <= Average < 70
o D: Average < 50

3. Print the Report:

 Write a function print_report() that prints a detailed report of each


student’s performance. The report should show:
o Student ID
o Total Marks
o Average Score
o Final Grade
 Use string concatenation to format the output neatly.

NOTE: Avoid Hard-Coding:

Your program should work for any number of students provided by the user. It should
dynamically generate unique IDs, assign random marks, and produce individualized reports.

Submission Guidelines:

 Paste your .py file code with proper comments explaining each function and its purpose.
 Include a screenshot output for a sample run of your program with at least 5 students.

Sample Example of Screenshot Output:


Virtual University of Pakistan SEMESTER FALL 2024

Note: Plagiarism will be checked for the solution provided. Marks will be
awarded based on your answer and plagiarism report.

For any query about the assignment, contact at email [email protected]

You might also like