Closed Siddiq200 closed 6 years ago
And I did not understand this line ?
assignmentsThisCourse[FieldType::isMinor].push_back(l_False);
I have worked on Java I am New to C++ and OpenWBO
Changes:
bool
so that it behaves as you expect, as your case has three possible values.assignmentsThisCourse[FieldType::isMinor].push_back(l_False);
means that a variable in the solver to specify whether the course is minor is assigned to false. Since the original code has it as a boolean value, a single variable was sufficient. In your case, if you want three values, you could replace it with two variables, as in the case of program. Other changes in the parser are fine.isLabCourse()
and slotInLabTime()
similar to the existing functions for minor.The above should probably be sufficient. If Lab and Minor are independent of each other (i.e., if a course can be both), you could alternatively add a new field for is_lab
, and copy code from is_minor
.
With the Above changes, adding two variables as you suggested in point 2 worked for me.... Thanks a lot.
As you mention in 3rd point I Remove If-Else to avoid any unexpected behaviour.
As you assume I have already defined isLabCourse()
and slotInLabTime()
similar to the existing functions for minor.
Now I can use 3 values for isMinor :)
Thanks for making Repository public. Thanks for Help.
I want 3 values for IsMinor ie. Yes, No, Lab ? Can you give me some guidence for this ?
I have changed
Minor.h:
Parsing Input:
Parsing YML:
Parser line 67:
ConstraintAdder: