Class LectureSeries
- java.lang.Object
-
- org.jacop.examples.fd.ExampleFD
-
- org.jacop.examples.fd.LectureSeries
-
public class LectureSeries extends ExampleFD
It is a simple logic puzzle about lectures.- Version:
- 4.7
Last week at school was made varied by a series of lectures, one each day (Monday through Friday), in the auditorium. None of the lectures was particularly interesting (on choosing a college, physical hygiene, modern art, nutrition, and study habits), but the students figured that anything that got them out of fourth period was okay. The lecturers were two women named Alice and Bernadette, and three men named Charles, Duane, and Eddie; last names were Felicidad, Garber, Haller, Itakura, and Jeffreys. Can you find each day's lecturer and subject?
1. Alice lectured on Monday.
2. Charles's lecture on physical hygiene wasn't given on Friday.
3. Dietician Jeffreys gave the lecture on nutrition.
4. A man gave the lecture on modern art.
5. Ms. Itakura (*5a) and the lecturer on proper study habits spoke on consecutive days, in one order or the other.(*5b)
6. Haller gave a lecture sometime after Eddie did.
7. Duane Felicidad (*7a) gave his lecture sometime before the modern art lecture(*7b)
Answer:
Monday, Alice Itakura, choosing a college Tuesday, Duane Felicidad, study habits Wednesday, Eddie Garber, modern art Thursday, Charles Haller, physical hygiene Friday, Bernadette Jeffreys, nutrition
-
-
Constructor Summary
Constructors Constructor Description LectureSeries()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static void
main(java.lang.String[] args)
It executes the program which solves this simple logic puzzle.void
model()
It specifies a standard way of modeling the problem.-
Methods inherited from class org.jacop.examples.fd.ExampleFD
creditSearch, getSearch, getSearchVariables, getStore, printMatrix, search, searchAllAtOnce, searchAllOptimal, searchLDS, searchMasterSlave, searchMaxRegretOptimal, searchMiddle, searchMostConstrainedStatic, searchOptimal, searchSmallestDomain, searchSmallestMedian, searchSmallestMiddle, searchSmallestMin, searchWeightedDegree, searchWithMaxRegret, searchWithRestarts, shavingSearch
-
-
-
-
Method Detail
-
model
public void model()
Description copied from class:ExampleFD
It specifies a standard way of modeling the problem.
-
main
public static void main(java.lang.String[] args)
It executes the program which solves this simple logic puzzle.- Parameters:
args
- no arguments is used.
-
-