Prolog, Computer Engineering

Prolog:

Still we can take our card game from the previous lecture like a case study for the implementation of a logic-based expert system. So there the rules were: four cards are laid on the table face up. Now Player 1 takes the first card, they take it in turns until they both have two cards each. And to see who has won, and they each add up their two card numbers, the winner is the one with the highest even number. So there the winner scores the even number they have. But see if there's no even number, and both players achieve the same even number, so then the game is drawn. Than it could be argued that undertaking a minimax search is a little avoidable for this game, this means that we could easily simplified a set of rules for each player, and so that they choose cards rationally. Just to demonstrate this, there we will derive down some Prolog rules that specify how player one should choose the first card.

For more understand we see example, assume there the cards dealt were as: 4, 5, 6, 10. So now in this case, there the best choice of action for player one is to choose the 10, and followed presumably by the 4, hence player two will pick the 6. After that we need to abstract from this particular example to the general case as: we see such there were three even numbers or one odd one, and according that player one is guaranteed another even number to match the one they chose for match.

Posted Date: 1/10/2013 5:58:08 AM | Location : United States







Related Discussions:- Prolog, Assignment Help, Ask Question on Prolog, Get Answer, Expert's Help, Prolog Discussions

Write discussion on Prolog
Your posts are moderated
Related Questions
What are the Counters? 1. The Counter is a sequential circuit which consists of a set of flip flops connected in a appropriate manner to count the sequence of input pulses.

what are advantages and disadvantages of bresenham''s line drawing algorithm?

Define cache memory? A special very high speed memory known as a cache is sometimes used to increase the speed of processing by making current programs and data available to th

Problem 1. Explain briefly the process of matching production rules against working memory 2. What are the different kinds of knowledge that need to be represented in AI? Ex

Q. Explain about Hexadecimal Numbers system? Hexadecimal system has 16 digits that are represented as 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F. A number (F2) H is equivalent to

Question: a) Write a small program using floating-point operations in Reverse Polish Notation to evaluate the following: Volume of Sphere = (4/3)πr 3 Consider that the u


How can I open an MS Access database that has been converted to a current version? Ans) MS Access is not backwards compatible. A workaround to share tables among different versi

What are the factors determine the control signals? Contents of the control step counter Contents of the instruction register Contents of the condition code flag