AI Index

4
INDEX SR NO AIM DATE OF PRACTI CAL SIGN REMARK S 1 Write a program which contains three predicates: male, female, parent. Make rules for following family relations: father,mother, grandfather,grandmother, brother, sister, uncle, aunt, nephew and niece. 2. Write a program that list four addresses in a label form, each address should list a name, one-line address, city, state & pin-code. 3. Write a program for diagnosis the childhood diseases. 4. Write a program to find roots of quadratic equation.(consider all possible cases) 5. Write a program to find minimum & maximum from give Numbers. 6. Write a program to solve Water-Jug Problem. 7. Write a program to find factorial of given number. 8. Write a program to input user name and password from user and repeatedly asking if any one of them is wrong. 9. Write a menu driven program to display set of questions to user and give answer of selected question. For Ex. Q-1. Who likes apple? Q-2. Does anybody like apple? Q-3. Is it true that nobody likes apple?

Transcript of AI Index

Page 1: AI Index

INDEX

SR NO AIM

DATE OF PRACTICA

LSIGN REMARKS

1

Write a program which contains three predicates: male, female, parent.Make rules for following family relations: father,mother, grandfather,grandmother, brother, sister, uncle, aunt, nephew and niece.

2.Write a program that list four addresses in a label form, each address should list a name, one-line address, city, state & pin-code.

3. Write a program for diagnosis the childhood diseases.

4. Write a program to find roots of quadratic equation.(consider all possible cases)

5. Write a program to find minimum & maximum from give Numbers.

6. Write a program to solve Water-Jug Problem.

7. Write a program to find factorial of given number.

8. Write a program to input user name and password from user and repeatedly asking if any one of them is wrong.

9.

Write a menu driven program to display set of questions to user and give answer of selected question.For Ex. Q-1. Who likes apple?Q-2. Does anybody like apple?Q-3. Is it true that nobody likes apple?Q-4. Who likes apple as well as enjoys playing cricket and piano?Q-5. Does anybody play at least one instrument?Q-6. Who likes to play chess, drink buttermilk but does not play any instrument?Q-7. Who share at least one hobby and at least one instrument?Q-8. Who are the persons sharing common instruments but no hobbies are in common?

Page 2: AI Index

1

Enter Question No For Ans :: 4.jollyfalse.

10.

Players in a certain club are divided into three leagues, and players may only challenge members in their own league or the league below (if there is one). Write a program that will display all possible matches between club players.

11

Write a PROLOG program based on list: (a). To find the length of a list.(b). To sum all numbers of list.(c). To find whether given element is a member of a list.(d). To Append the list.(e). To Reverse the list.(f). To find the last element of a list.(g). To delete the first occurrence of an element from a list.(h). To delete the every occurrence of an element from a list.(i). To find Nth element from the list.(j). Given are two lists, merge the element present at odd numbered locations in given two lists into third list, and merge the element present at even numbered locations in given two lists into fourth list and display all four lists.

12

Write a PROLOG program for Arithmetic Operations: -(a). To add the member of a given list.(b). To check if a given year is a Leap Year or not.(c). To find the Greatest Common Divisor.(d). To find the Least Common Divisor.(e). To find the factorial of a given number. (f). To generate the fibonacci series of a given number.(g). To convert an integer number into a string of equivalents binary

13 Write a PROLOG program to implement Tower Of Hanoi Problem.

14. Write a PROLOG program for finding the average salary of an employee and for adding and deleting employees from the database.

Page 3: AI Index

2

15. Write a PROLOG program to demonstrate the effective use of Cut and Fail.

16. Write a PROLOG program for traveling salesman problem.

17. Write a PROLOG program for monkey banana problem.

18. Write a PROLOG program N-QUEEN problem.

19. Assignment