1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
OlgaM077 [116]
2 years ago
14

Course Aggregation Many times, departments are only interested with how students have done in courses relative to a specific maj

or when considering applicants for admission purposes.
For this problem you are given a dictionary where the keys are strings representing student ids and the values are dictionaries where the keys represent a course code and the value represents a grade. Your task is to write a function that given a dictionary of the described format and a prefix for course codes, return a dictionary where each key is a student id and the corresponding value is the average grade of the student only in courses that start with the given prefix.
def course_grader (student_to_grades, course_prefix): ({str, {str, float}}) -> {str, float} I: a dictionary containing the grades of students (as described above) and a course code prefix P: compute and store the average grade of all students only for courses that start with the given course prefix 0: a dictionary of student ids to average grades as described in the Processing step pass
Computers and Technology
1 answer:
nadezda [96]2 years ago
8 0

Answer:

def course_grader(student_to_grades, course_prefix):

   student_grades = dict()

   for key, value in student_to_grades.items():

       grade_score = 0

       for course,grade in value.items():  

           if course_prefix == course:  

               grade_score += grade

                student_grades[key] = grade_score / len(value.keys())

   return student_grades

Explanation:

The course_grader function is a python program that accepts two arguments, the student dictionary and the course prefix. The function returns a dictionary of the student id as the key and the average grade of the student as the value.

You might be interested in
How to get an hdmi working from a chromebook?
igomit [66]
Use an adapter, costs money though.
8 0
3 years ago
Read 2 more answers
Thomas asked his friend for a software suite. His friend had the software suite in his computer and he copied it into a small, r
Misha Larkins [42]

Answer:

The correct answer to the following question will be "Flash memory card".

Explanation:

A flash memory card seems to be a storage (small) medium which stores data or information on fordable or remote devices using non-volatile transistor technology hardware.

  • Most newer offerings include flash storage or memory chips, even though the development of other memory innovations is underway.
  • This would be the storage mechanism from which the configuration tool was replicated by Thomas' friend.
8 0
3 years ago
People are starting to type in whole questions rather than specific words, which leads credence to having _____ that have this a
SpyIntel [72]

Answer:

a. corporate blogs

Explanation:

corporate blog is the practice of creating content that addresses various topics which includes (updates, expert tips or best practices and company news) from the perspective of a brand. Also, blogs make posts and comments easy to reach and follow.

4 0
3 years ago
How to code for a database?​
olganol [36]

Answer: <em><u> How to code for a database?​ A database is an organized collection of data, generally stored and accessed electronically from a computer system. Where databases are more complex they are often developed using formal design and modeling techniques. </u></em>

WWW. Wikipedia.com

Explanation: When creating a database first you need to make a software program then you need to start planing on what to do ...

{ A database management program (DBMS) is a software package design designed to manipulate, define, retrieve, and manage data in database.

A DBMS generally manipulates the data itself, the the data format, field names, record structure and file structure.}

<h3><u><em>HoPe ThIs HeLpS YoU!!</em></u></h3>

<u><em /></u>

7 0
2 years ago
A company needs to store its documents in one place, share news and information with all staff, and allow access for employees w
Greeley [361]
An NAS
Would do The Trick
4 0
2 years ago
Other questions:
  • Semiconductor memory is used mainly for primary storage even with its high cost. In another hand, the magnetic tape is the cheap
    6·1 answer
  • In order to average together values that match two different conditions in different ranges, an Excel user should use the functi
    6·1 answer
  • An individual who understands and uses a variety of symbols yet uses one symbol at a time to share a message needs more developm
    10·1 answer
  • Is backing up computer files done on the hard drive?
    14·2 answers
  • Who can search the internet and select element base on important words
    13·1 answer
  • Is it possible to have a deadlock involving only oneprocess? Explain your answer.
    11·1 answer
  • Can someone explain what Bytes are? I would really like to know.
    5·2 answers
  • What are examples of Table Tools options that can help edit data?
    15·2 answers
  • WILL GIVE BRAINLIEST!!!!!! 10 POINTS!!!!
    14·2 answers
  • What is the output for the following program?
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!