We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1
KIET Group of Institutions, Ghaziabad
Department of Computer Science & Information Technology
(An ISO – 9001: 2015 Certified & ‘A+’ Grade accredited Institution by NAAC)
Assignment No.-2 (2024-25) Odd Semester
Python Programming (BCC302)
Problem 1: Advanced List Slicing and Manipulation
Problem Statement: Given a list of integers, write a Python function rearrange_list(lst) that rearranges the list so that all even numbers appear before all odd numbers. The relative order of even and odd numbers should be preserved. The function should perform this rearrangement using list slicing and comprehensions without using built-in sorting functions.
Problem 2: Dictionary Value Aggregation
Problem Statement: You have a list of dictionaries where each dictionary represents a student and their scores in various subjects. Write a Python function aggregate_scores(students) that aggregates the scores for each subject across all students and returns a dictionary with the total scores per subject.
Note:
ü Write Assignment on A4 Size Page only (Hand Written) and then convert to PDF
ü Write your Name, Roll Number and Assignment Number on top of page.