Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Objective: Create a Python program that stores student scores for multiple subjects using a combination of lists and dictionaries. Bob': { Math ' : 7

Objective: Create a Python program that stores student
scores for multiple subjects using a combination of lists
and dictionaries.
Bob': {Math': 78,Science': 82,English': 88}}
Tasks:
Create a new list called student_names that
contains the names of all students.
Add a new student named 'Alice' to the scores
dictionary with scores for the same subjects (Math,
Science, and English).
Write a function called average_score(subject) that
takes a subject name as input and returns the
average score for that subject across all students.
Use the student_names list to iterate over each
student's scores and calculate their overall average
score using the average_score(subject) function.
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Larry Ellison Database Genius Of Oracle

Authors: Craig Peters

1st Edition

0766019748, 978-0766019744

More Books

Students also viewed these Databases questions

Question

How did Jennys hoarding interfere with her life?

Answered: 1 week ago