Map list to another

Hi everyone,
I have two lists and I want to map a list to another. one of them just a list of Boolean.
I think the picture will explain better than works

What have you tried so far? You’ve actually shown the exact logic in your drawing for the first part and the second part is just a conditional statement.

I have list of elements and I want to add (Null) if the bool is false into this list … add not replacing the elements in the list

I understand, but you need to show an attempt before we suggest an answer. This is not a forum for doing other people’s work. We want to know what specific issues you’re having or where you’re confused so that we can offer guidance and help you learn.

I am sorry I don’t have the script for now I only have this photo. I just need to insert an intem to index but the problem is when the index isn’t existing already in the list , then node isn’t working

An if statement can accomplish what you’re looking for:

bools = DSCore.List.Contains(lst2,lst1<1>);
out = bools? lst1: null;
4 Likes

Well we can’t really help you without a script. As I mentioned before and @EdsonMatt has now shown, it’s possible with a simple conditional statement.

Thank you so much for your effort… that’s very helpful
we also found another solution maybe could be useful for anyone