![]() ![]() The database also contains facts and rules let us consider the example “Sumit has a car.” We can declare the original relationship between two objects where one object is Sumit. The program in prolog specifies the relationship between objects and the properties of objects the family trees tell us how to construct a database of family. grandfather(M,O): father(M,N), parent(N,O).grandmother(M,O): mother(M,N), parent(N,O).grandparent(M,N): parent(M,O), parent(O,N).We can also write the syntax for some other relationships as follows: ![]() Where _(underscore) indicates that it is an anonymous variable. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |