Comparing two lists for Cull Pattern component

Hello, u i want to make cull pattern. Whats the easiest way for creating output as i show on the picture. I have 2 lists for input. One list is items that im searching for in “database”, and the second list is a database. As output i want to have pattern like in the picture

I only came up with solution like seen on picture below.

Because my two inputs panels only have unique values insede them i can use my solution.
Database always will have only unique entries, but values that i am searching are user defined, so it would be better to be fool-proof. My solution unfortunately isnt. When user accidentaly will search the same values for example “1, 2, 3, 3, 4…” my algorithm will not work properly

This seems fine to me. What is the expected result if the user enters duplicates ?
If you want to remove duplicates you could use Create Set. Member Index could also be useful to test for item presence.

1 Like