I am trying to make something like a list dictionary in Prolog. I want to transfer a list of numbers from German to English.
Input:
trnslt([eins,drei,neun],X).
Output:
X = [one,three,nine]
I've thought of an idea to make an if statement but then I thought this won't work.
I would be thankful if anyone provided me with the idea and the code to fully understand the concept.
Edit: I have read the answers on this question and got the clauses, but actually did not understand anything actually, so can someone tell me how it works?