FOR JAVA, without importing libraries.
Create a public final class named Course. Course should not provide a public constructor, although you will probably want to create a private one. Instead, Course should provide a class method named fromCSV which takes a single String argument and returns an array of Course instances.
Each Course maintains a department and a number, both Strings. FOR EXAMPLE, given the following CSV contents:
CS, 125
IE, 333
MUS, 230
You should return an array containing three Course instances: the first with department="CS" and number="125", the second with department="IE" and number="333", etc. Your array should contain the courses in the same order in which they appear in the CSV String. (Your fromCSV method should assert that the passed String is not null. )
Finally, Course should provide getters for the department and number named getDepartment and getNumber, respectively