Question: PROLOG PROGRAMMING PROLOG PROGRAMMING Please dont use any other programming language apart from prolog. Also, Show the screenshot of output. Question 1 Write a Prolog
PROLOG PROGRAMMING PROLOG PROGRAMMING Please dont use any other programming language apart from prolog. Also, Show the screenshot of output.

Question 1 Write a Prolog program named between_ints.pl so that between_ints(l,J.K) is true iff K is an integer between integers I and J inclusive. between_ints(3, 20, 5). should be true between_ints(3, 20, 20). should be true between_ints(3, 20, 21). should be false Question 2 Write a Prolog program named p.pl so that p(X) is true if X is a list consisting of n a's followed by m b's for some integer n. p(a, a, b, b]). should be true p((a, b, b, b]). should befale Question 3 Write a Prolog program named list min.pl so that list_min(LM) is true if M is the smallest element in the list L. The list will not be empty. list min([5, 2,7, 1, 3,1). should be true list min([5, 2,7,1,3],2), should be false Question 1 Write a Prolog program named between_ints.pl so that between_ints(l,J.K) is true iff K is an integer between integers I and J inclusive. between_ints(3, 20, 5). should be true between_ints(3, 20, 20). should be true between_ints(3, 20, 21). should be false Question 2 Write a Prolog program named p.pl so that p(X) is true if X is a list consisting of n a's followed by m b's for some integer n. p(a, a, b, b]). should be true p((a, b, b, b]). should befale Question 3 Write a Prolog program named list min.pl so that list_min(LM) is true if M is the smallest element in the list L. The list will not be empty. list min([5, 2,7, 1, 3,1). should be true list min([5, 2,7,1,3],2), should be false
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
