Take elements from list one by one

I’m using: SWI-Prolog version

I want the code to: Take elements from list one by one

But what I’m getting is:

My code looks like this: findall(E,Zen(A,B,E,D),Z)

How can i take the elements from the list Z one by one ?

% your code here

I think you want to use member/2?

findall/3 collects the solutions to a goal, which may not be what you are looking for,