...Yet another list sorting problem


#1

So, I have two lists of Z coordinates (In this case of spaces and levels) and I want to check List B against List A and for each item in B return the index of the item it matches in A. (I want to sort rooms/spaces in a linked model by the level that they (Most closely) match in the current model).

I worked out how to do this with a list and a single value using filter by boolean, but so far not managed to find a way to check if listed items are in another list…

I will keep trying but if anyone has a good method it would be appreciated :slight_smile:

Lists


#2

Joseph, use the node If Equal Return Index, that should be what your after?

Equal


#3

Ah, thanks. Thats a nice simple solution


#4

That worked great. Heres levels being assigned to a list of z coordinates from a linked model:

Levels Levels Levels