Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

write a simple SWIFT program that does the following: (1) create a course struct that has course name, semester (for example Spring 2020), and grade.

write a simple SWIFT program that does the following:
(1) create a course struct that has course name, semester (for example Spring
2020), and grade.
(2) create a student class that has student id, student name, list of courses (list
of the struct course), and level.
(3) Level is an enum that can be Undergrad, Grad, and Audit.
(4) The student class must have an initializer with student, student name, and level
The student class will have 2 function:
(5) addCourse
(6) listCourses (function will loop through the list of courses and display course name,
semester, and Grade)
(7) Create a static function that add instances of student class to a list of students.
(8) Create a static function that loops through the list of students and lists the students by
their level that is, you will produce 3 lists: Undergrad list, Grad list, and Audit List

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

Concepts of Database Management

Authors: Philip J. Pratt, Joseph J. Adamski

7th edition

978-1111825911, 1111825912, 978-1133684374, 1133684378, 978-111182591

Students also viewed these Databases questions