Hi all, could you please help me? I’ve been struggling with this problem for a while now. Here is a picture and values in a script.
sortListByKeysAndAddEmptyList.dyn (24.6 KB)
Hi all, could you please help me? I’ve been struggling with this problem for a while now. Here is a picture and values in a script.
@Drbohlav You can do something like this with OOTB nodes:
Or maybe just stick with Python since it’s simpler!
OUT = [IN[2][IN[1].index(x)] if x in IN[1] else [] for x in IN[0]]
Another option: You’re just creating a dictionary with unused keys. Set the values for the known keys and then set the rest equal to your default value.