Back to the 2022 paper

Module 2: Knowledge Representation and Reasoning

20227m

Write a Prolog program that verified whether an input list is a palindrome.

Hint:
Goal : Palindrome ([r, a, c, e, c, a, r])
Output : Yes
Goal : Palindrome ([a, b, c])
Output : No

Similar questions