Hi I would appreciate some help with the following, thank you...
Given the following Database:
item_costs(hat,3).
item_costs(coat,5).
item_costs(jacket,7).
item_costs(shoes,3).
item_costs(trousers,6).
item_costs(scarf,4).
where item_costs(X,Y) is defined as item X costs Y euros.
1) write a rule costs_less(X,Y) which is true if item X costs less than item Y.
-What results would would your rule return in answer to the query:
costs_less(X,5).
2)write a rule costs_more(X,Y) which checks if item X costs more than item Y.
-What results would your rule return in answer to the following queries:
costs_more(scarf,shoes).
costs_more(Jacket,scarf).
costs_more(X,Y).
Given the following Database:
item_costs(hat,3).
item_costs(coat,5).
item_costs(jacket,7).
item_costs(shoes,3).
item_costs(trousers,6).
item_costs(scarf,4).
where item_costs(X,Y) is defined as item X costs Y euros.
1) write a rule costs_less(X,Y) which is true if item X costs less than item Y.
-What results would would your rule return in answer to the query:
costs_less(X,5).
2)write a rule costs_more(X,Y) which checks if item X costs more than item Y.
-What results would your rule return in answer to the following queries:
costs_more(scarf,shoes).
costs_more(Jacket,scarf).
costs_more(X,Y).