Added Jesse's changes and fixed the bug in generateSchedule that was preventing the course array from being properly accessed