hi
This clause determines if B = 2*A ( d(A,B) )via the next definitions.
d(0,0).
d(s(X),s(s(Y))):- d(X,Y).
Here s is the suc. function.
Now i need to modify this to be able to implement the relation
'is smaller than 2 times of'. with other words
p(X,Y) is true if x < 2 * y.
Can anybody help me plz?
This clause determines if B = 2*A ( d(A,B) )via the next definitions.
d(0,0).
d(s(X),s(s(Y))):- d(X,Y).
Here s is the suc. function.
Now i need to modify this to be able to implement the relation
'is smaller than 2 times of'. with other words
p(X,Y) is true if x < 2 * y.
Can anybody help me plz?