Robert98, what are you really trying to achieve? Based upon your use of the code harvested from the link you provided I must deduce you are in a little over your head, so let's step back and understand what it is you want to learn and/or achieve.
Without the benefit of the above it almost appears as if you are trying to construct an intersection function, that is, determine the list elements common to two lists (like set theory intersection).
If so AND you don't wish to use vlisp functions this unoptimized code might illustrate:
(defun venn_inters ( list1 list2 / result )
(foreach element list1
(if (member element list2)
(setq result (cons element result))
)
)
(reverse result)
)
example:
(venn_inters
'(10 12 14 15 13)
'(74 1114 12 13 15 18)
)
returns (12 15 13)
As such, nested foreach loops are not required, but I may be misinterpreting what you want to achieve. Also note that they are many ways to return the intersection of two lists, this was simple one using foreach.
An aside, while the do and for code provided in the link in your first post may have some mild academic value, from a practical stand point, i.e. what is used in typical day to day programming, they have little value for the majority of programmers imo, certainly not n00bz (no offense) and accordingly suggest you use tutorials that are more interested in helping the student new to lisp establish a solid knowledge base, rather than illuminate the teacher's prowess.