Skip to content

PMASIAUJ - Section 3.5, Exercise 5 question #112

Answered by jomifred
mindcrime asked this question in Q&A
Discussion options

You must be logged in to vote

and for a generic cheapest rule, a first draft could be

cheapest_beer(Ag,N1) :-
     price(beer, N1)[source(Ag)] & not (price(beer, N2)[source(_)] & N2 < N1).

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@jomifred
Comment options

@mindcrime
Comment options

Answer selected by mindcrime
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants