2AI
2AI
2AI
Q1. Explain how AND and OR tree can be used to represent games. What limitations do
you think a system that uses game tree to play chess might face. Would it face different
limitations if it played Tic Tac Toe.
Answer: - AND and OR are the decision trees which can be used frequently in playing games.
These trees provide an effective way for options and the possible results by choosing those
options. Also decision tree helps in controlling the outcomes as result. AND and OR decision
trees provide an effective method of decision making because they help us to make the best
decisions on the basis of existing information.
Limitations: - Decision tree is created to find all possible moves. In chess, there are infinite
possible moves and it depends on ability. There are different types of moves in chess and
according to them decision trees will be made and it will become very complex. So Decision
trees have limitation in playing chess
In case of tic tac toe, central node will give the maximum winning options. There is no decision
tree which is complex so no limitation is there while playing TIC TAC TOE.
Answer: - A predicate logic is a programming language as how to write various expressions and
the meaning of the expressions in formula. For making a predicate logic needs: - logical symbols
like and, or, not, equality, true, false, predicate and function symbols like man(x) for x is a man,
term like variables and functions , a formula which is combination of terms and logical symbols,
a sentence like formula without free.
Example: - Let “a” is a perfect square and it is a predicate whose truth depends on the value of
a.
Chicken is food.
Answer: -
PART-B
Q4. What problem would be encountered in attempting to represent the following
statements in predicate logic? It should be possible to deduce the final statement from the
others:
People do not do things that will cause them to be in situation that they do not like.
Answer: -
- A predicate p is unsatisfiable if and only if, it is false for all possible values of
appropriate type.
And if there is any relation we might be able to have a predicate logic in between them
Queue queue;
queue.Enqueue(root);
Node * currentNode;
while(currentNode = queue.Dequeue())
if(currentNode->data == searchVal)
return currentNode;
queue.Enqueue(currentNode->left);
queue.Enqueue(currentNode->right);
}}
Q6. Compare Declarative and Procedural knowledge and describe the areas in which each
can be applied.
Answer: -
Declarative Procedural
These are the statements about the truth. To know that how to perform a problem.