Answered step by step
Verified Expert Solution
Question
1 Approved Answer
ou are given a set of facts of the following form in hw 3 - handout / query / facts . pl: novel ( name
ou are given a set of facts of the following form in hwhandoutqueryfactspl:
novelname year
Here name is an atom denoting the name of the novel and year denotes the year
that the novel has been published.
For example, the fact novelthekingkillerchronicles, says that
the novel named thekingkillerchronicles was published in the year
fanname novelsliked
Here name is an atom denoting the name of the person and novelsliked denotes
the list of novels liked by that person.
For example, the fact fanjoeylittlewomen says that the person named
joey is a fan of the novel named littlewomen.
authorname novelswritten
Here name is an atom denoting the name of the author and novelswritten
denotes the list of novels written by that author.
For example, the fact
authorgeorgerrmartin, asongoficeandfireseries says that the
author named georgerrmartin has written the novel named
asongoficeandfireseries.
Complete the definition of the predicate yearnovelsBook in
hwhandoutqueryquerypl which is true if Book is a novel that has been published
in either or
Complete the definition of the predicate periodnovelsBook in
hwhandoutqueryquerypl which is is true if Book is a novel that has been pub
lished during the period to
Complete the definition of the predicate lotrfansFan in
hwhandoutqueryquerypl which is true if Fan is a name of a person that is a fan
of thelordoftherings.
Complete the definition of the predicate authornamesAuthor in
hwhandoutqueryquerypl which is true if Author is an author whose novels
chandler is a fan of
Complete the definition of the predicate fansnamesFan in
hwhandoutqueryquerypl which is true if Fan is a person who is a fan of the
novels authored by brandonsanderson.
Complete the definition of the predicate mutualnovelsBook in
hwhandoutqueryquerypl which is true if Book is a no
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started