Question: write a python code!!! Write a class Student with the following attributes (make sure the attributes are private using name mangling): name: String id :


write a python code!!!
Write a class Student with the following attributes (make sure the attributes are private using name mangling): name: String id : Integer courses: List of Strings grades: List of Integers The class must include the following operations: A constructor that receives as input the name and id. Getters for each attribute. add_course(course: String, grade: Integer) : Bool -- This operation adds the course name to the list of courses and the grade to the list of grades. The method must confirm before adding that the course is a String and the grade is an Integer, otherwise the operation won't be performed. The method must return True if the course and grades were added, False otherwise. _str_0 -- Should return the following information Student name:
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
