Question: I will give thumbs up for it Reading and understanding the following python program. Please write the outputs. class Dictcourse (): def __init__(self, courses): ,
I will give thumbs up for it

Reading and understanding the following python program. Please write the outputs. class Dictcourse (): def __init__(self, courses): , self. courses = courses def get_courseName (self, key): if key in self.courses. keys (): return self. courses [key] else: return ('not found') def update_course (self, newkey, newvalue): self. courses [newkey] = newvalue return self.courses def delete_course (self, key): if key in self.courses. keys(): del self. courses [key] return self. courses else: return ('not found') my_courses = Dictcourse({'101':'Python', '102':'Math', '103':' Chinese' }) print (my_courses.get_courseName ('101')) print (my_courses. update_course ( 104','English')) print (my_courses. delete_course ('102))
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
