How to get every index of array that has the same item?

I’m having an integer array which has a lot of index and every index has it’s own item. At some indexes, the items are equal and when I use the FIND node, then it is only giving me the first index with that item. I thinking about a loop but I don’t see how could I connect it. If possible, I don’t want to make a remove and add index since I need the array later

If the items are intergers.you could try this.

how to use indexes:

1 Like

What are the “local indexes” for? My array has 36 indexes (from 0 to 35) and every item is 0 at the start. After some events, 1 starts adding to certain indexes. Later I want to get back the X biggest item’s index. So I only has an array with indexes and items

local indexes is an empty array by default.when the function runs it creates the temporary array,and indexes are adding to it.at the end it passes the array to outside.then you can use it to find items in your interger array.

1 Like

Ah, I see, I will try this out tomorrow! Thank you!

1 Like