Answered step by step
Verified Expert Solution
Question
1 Approved Answer
To monitor enrollments each semester, I have a spreadsheet that contains a list of courses with names, enrollments, and capacities. I read the spreadsheet data
To monitor enrollments each semester, I have a spreadsheet that contains a list of courses with names, enrollments, and capacities. I read the spreadsheet data into a Racket list that looks like this:
Dept "Number" "Section" "Class Nbr "Capacity" "Enrolled"
CS
CS
CS
CS
The first item in the list is the header row in the spreadsheet. It is not part of the data.
The dean and provost frequently ask me for various summary data, such as total enrollments or remaining capacity.
Write a Racket function named minopenseats that takes such as a list as its only argument. It returns the minimum number of open seats available in any section. For example:
define example ; the data shown above
minopenseats example
CS has open seats. The other classes have and open seats respectively.
I have provided a checkequal? expression for this example. Write at least two more checkequal? expressions to test your solution.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started