?- consult(prepost). % prepost compiled 0.00 sec, 956 bytes true. ?- prefix([a,b,c],[a,b,c,e,f]). true. ?- prefix([a,b,c], [a,b,e,f]). false. ?- prefix([a,b],[a]). false. ?- prefix([],[a,b,c,d]). true. ?- prefix(X,[a,b,c,d]). X = [] ; X = [a] ; X = [a, b] ; X = [a, b, c] ; X = [a, b, c, d] ; false. ?- postfix([n,e],[d,o,n,e]). true . ?- postfix([],[a,n,y,t,h,i,n,g]). true . ?- postfix([a,b,c],[a,b,c,d,e]). false. ?- postfix(X,[a,b,c,d]). X = [a, b, c, d] ; X = [b, c, d] ; X = [c, d] ; X = [d] ; X = [] ; false.

my first idea was to use this :

sublist(_List1, _List2).

but when I tested it, it didn't really work... then I thought about just using the word prefix

prefix(_List1, _List2).

I am just not sure where to go with this. My teacher said to use lists but not sure what i should be doing. Thanks