In this assignment you will enhance the university model from A5 that consisted of the Department, Person, Student, and Faculty classes. The goal of the enhancements is to allow the creation of an individual course section for a given semester and the assignment of a faculty instructor. Once established students can be registered for the course.
To support this expanded model University, Catalog, and Course classes must be created. University will serve as a container for Department, Catalog, and Student objects. A Catalog object represents a container for all courses in a given semester – for example, Fall 2020 (“F2020”). Course objects will be created for each course section, will be a container for Student objects, and will be placed in the Catalog container object.
A zipped folder that’s a Python package called “A8PackageBB” is provided that includes:
• application – a .py file that’s to be run as a short application
• DataSetUp – a .py file containing a single function that creates some data, loads it into instantiated class objects, and returns one University object and one Catalog object to the calling code in ‘application’
• classes – a .py module containing code for all required classes
To do the above work must be done in the ‘classes’ module. For the University, Catalog, and Course classes, the class signature, init method, and str method are provided. You must provide code for the other
methods (“provide code”). Each has a docstring that describes how to code the method. They are mostly accurate, but be prepared to make adjustments to fit whatever you discover.
You will need to inspect the provided code to understand what needs to be done. However, most code has been provided.
After you complete the above, run the ‘application’ code in A8PackageBB to run the simple application to create courses, add students, print students in a course, or print courses in a catalog. ‘application’ is provided, so you can inspect the code and use it as is, or modify it if you need to do so. ‘application’ does all the module imports and runs the ‘DataSetUp’ function to create objects for Department, Student, and Faculty. It also sets up University and Catalog objects, for which there will only be one of each for this assignment. The main purpose of ‘application’ is to create courses (Course objects) to be placed in the Catalog object and add students (“register”), which will be done by placing Student objects in the Course object.
You may reuse the Department, Person, Student, and Faculty classes you created for previous assignments, but you may have to make changes to them so they run with ‘application’. I suggest you use the copies I provide if at all possible.
The application menu is below, showing the functions it supports: Menu = """
1. Create Course
2. Add Students to Course
3. Print Students in Course
4. Print Courses in Catalog
A brief description of the above functions:
1. Create a Course prompts the user for the course Department code (ENGR, ARTS, or CSci), number (e.g. 101), and title (e.g. “Introduction to Engineering”). A list of Faculty names for the selected Department is displayed and the user selects one and types it in when prompted for the instructor. The Course object is created and is added to the (only) Catalog object, “F2020”.
2. Add Students to Course. The user is prompted for the name of a course that was previously created (e.g. “ENGR-101”) and is presented with a list of student names taken from the master list held by the (only) University object “GMU”. The user selects the number corresponding to the student on the list and the code adds that student’s object to the course. Subsequent students can be added by re-selecting ‘Add Students to Course’.
3. Print Students in Course. The user is prompted for a course name, the names of all students registered for the course are displayed.
4. Print Courses in Catalog. There is only one Catalog object, so no need to prompt. Just displays the courses whose objects are in the catalog including the name, instructor name, and number of students registered.
In summary, to create and test this assignment:
1. Unzip the provided folder/directory, which is set up as a Python package, and do all code work in it
2. Provide all method code to complete the University, Catalog, and Course classes
3. Run ‘application’ to test the menu functions
4. Make changes to the above classes as needed to ensure the application functions correctly
5. When done, zip up the folder/directory and submit it to Blackboard
This assignment has been answered 6 times in private sessions.
Or buy a ready solution below.
© 2022 Codify Tutor. All rights reserved