Write prolog clauses to express therelationships

Assignment Help JAVA Programming
Reference no: EM13162563

Write prolog clauses to express the following relationships, given the parent relationship: grand-parent, sibling, cousin.

 

so far i have:

ancestor(X,X).

ancestor(X,Y) :- ancestor(X, Z), parent(Z, Y).

 

 

Reference no: EM13162563

Questions Cloud

How many grams of have been consumed : If 155 of wet is collected over water at 24 and a barometric pressure of 738 , how many grams of have been consumed? (The vapor pressure of water is 22.38 .)
Compute the volume in liters : Calculate the volume in liters of a 0.133mol/L copper (II) sulfate solution that contains 150.g of copper (II) sulfate (CuSO4).
Calculate the vapor pressure of pure ethanol : A solution of 53.6 g of glycerin in 133.7g of ethanol has a vapor pressure of 113 torr at 313K. Calculate the vapor pressure of pure ethanol assuming that glycerin is a non-volatile, non electrolyte solute in ethanol.
Compute the millimoles of copper sulfate : Calculate the millimoles of copper (II) sulfate the chemist has added to the flask. Be sure your answer has the correct number of significant digits.
Write prolog clauses to express therelationships : Write prolog clauses to express the following relationships, given the parent relationship: grand-parent, sibling, cousin.
What is ka for this acid : When 0.060 mol of propionic acid, C2H5CO2H, is dissolved in 500 ml of water, the equilibrium concentration of H3O+ ions is measured to be 2.41 x 10-3 M. What is Ka for this acid?
Effects of the strategies on both gdp and unemployment : One government strategy to provide for economic stability and encourage economic growth is to provide tax reductions or tax incentives for individuals and businesses. An alternative approach is to increase government spending to accomplish these g..
How many moles of oxygen were in the sample : If 5.50 of the unknown compound contained 0.183 of and 0.367 of , how many moles of oxygen, , were in the sample.
Derive an expression for the subsequent concentration : Derive an expression for the subsequent concentration of sodium chloride c in terms of c0, t, Q, and V. Make a sketch of c versus t and label the main features.

Reviews

Write a Review

JAVA Programming Questions & Answers

  Display student details and classes in applet

Display student details and classes they have enrolled in Applet. The Applet should have following features. Update and View.

  A java program that will prompt the user to input a file

Write a Java program that will prompt the user to input a file (document) in order to count the frequency of each word. This program will display the frequency of each word sorted alphabetically or by frequency (depending on the preference of the use..

  Write a java program to register students for a college

Project is for designing and developing a College Registration program. Write a Java program to register students for a college

  Method to calculate all primes in the range [2..n]

One commonly used method to calculate all primes in the range [2..n] is to start with the number 2, mark it as prime, and mark all its multiples (excluding itself) as not prime. Then, we find the next smallest unmarked number, mark it as prime, and m..

  Write method called median that accepts an array of integer

Write a method called median that accepts an array of integers as its parameter and returns the median of the numbers in the array.

  Wolves and sheep: design a game

This project is designed a game in java. you choose whether you'd like to write a wolf or a sheep agent. Then, you are assigned to either a "sheep" or a "wolf" team.

  Write java program to read in sequence of hourly temperature

Write down Java program which reads in sequence of hourly temperature readings over 24-hour period using arrays. Your program must find and show maximum and minimum temperatures.

  Write java program to find calories-conditional operator

Write down the answer for this program? Write down Java program (use Conditional (? Operator) which suggests number of calories a person must eat each day.

  Develop a program that will handle a golfer and his scores

develop a program that will handle a Golfer and his scores. The program will be comprised of two classes: a Golfer class that will manage all the golfer's scores and a Score class.This is a class designed to represent a golfer including his name, hom..

  Eclipse or netbeans environments

As recommendation, you can try to use Eclipse or NetBeans environments that are used also for other courses as: Introduction in Java programming and Intermediate programming.

  Build a graphical user interface for displaying the image

Build a graphical user interface for displaying the image groups (= cluster) in JMJRST. Design and implement using a Swing interface.

  Write java program to evaluate postfix expressions

Write a java program to evaluate postfix expressions containing complex numbers using a stack. This program should contain two classes.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd