How to find index of True and sort the branches?


1.gh (9.6 KB)

I want to find index of True in a tree.
Now the index of True in {0} is in {0;0}, while those in {1} is in {1;1}
I want to “sort” the branches so the index of True in {0} is in {0;0}, while those in {1} is in {1;0}

like this ?

1 Like

I think @netsonicyxf means something like this.


1A 2023.gh (8.7 KB)


Index of True Boolean.gh (11.8 KB)