Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

MEF Currioulum FlnwohartMake the MATLAB code work to achieve the following functions: Assume that you are trying to build an operation interface which allows the

MEF Currioulum FlnwohartMake the MATLAB code work to achieve the following functions:
Assume that you are trying to build an operation interface which allows the mechanical engineering students in UNT
to register for 9 of the MEEN 3000 level classes (which are highlighted in blue as shown in 2019-2020 MEE
curriculum flowchart).
In order to register for a MEEN class, students need to meet all the prerequisites as well as co-requisites. Once he/she
fulfilled all the conditions for a certain class, that class can be registered successfully. Otherwise the system will object
his request and give that student a reminder why he/she could not register for that class.
This is the script i have written but I keep getting this error message:
function registrationStatus = registerForMEENClasses(studentInfo)
meenClasses ={'MEEN3010', 'MEEN3020', 'MEEN3030', 'MEEN3040', 'MEEN3050', 'MEEN3060', 'MEEN3070', 'MEEN3080', 'MEEN3090'};
prerequisites ={{},{'MEEN3010'},{'MEEN3010', 'MEEN3020'},{'MEEN3030'},{'MEEN3040'},{'MEEN3030', 'MEEN3050'},{'MEEN3060'},{'MEEN3070'},{'MEEN3080'}};
corequisites ={{},{},{},{},{},{},{'MEEN3050'},{'MEEN3060'},{'MEEN3070'}};
registrationStatus = containers.Map(meenClasses, cell(size(meenClasses)));
for i =1:length(meenClasses)
currentClass = meenClasses{i};
currentPrerequisites = prerequisites{i};
currentCorequisites = corequisites{i};
% Check if all prerequisites are met
if all(ismember(currentPrerequisites, studentInfo.completedCourses))
% Check if all corequisites are met
if all(ismember(currentCorequisites, studentInfo.completedCourses))
registrationStatus(currentClass)= 'Successfully Registered';
else
registrationStatus(currentClass)= 'Corequisite not met';
end
else
registrationStatus(currentClass)= 'Prerequisite not met';
end
end
disp('Registration Status:');
disp(registrationStatus);
end
>> registerForMEENClasses
Not enough input arguments.
Error in registerForMEENClasses (line 14)
if all(ismember(currentPrerequisites, studentInfo.completedCourses))
Plz write a script that works.
image text in transcribed

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

Records And Database Management

Authors: Jeffrey R Stewart Ed D, Judith S Greene, Judith A Hickey

4th Edition

0070614741, 9780070614741

More Books

Students also viewed these Databases questions

Question

1. Explain how business strategy affects HR strategy.

Answered: 1 week ago