Sum up and set value to room in list

Hi, I want to get the unique room and sum up their value by key on the right… is it possible?
e.g. room 889806 occurs 2 times, and by checking the value on the right, it should be 1560+1010


It would be helpful to see more of your graph. There’s probably a better way to handle this.

With what you have, you could count up the number of items in each sublist on the left and then duplicate the values on the right for each item. That should give you matching sublists of Rooms and Values. From there you can flatten both lists and group by key (Room).

like this?

I found solution by myself by making the right list same length to left first…(ofrepeatitem)
and then use list.allindiceof → getitematindex

GroupByKey node would probably work much better, but as @Nick_Boyts pointed out, we don’t have enough context to really help too much.

yes I use your method by equalling both side first. Then I found groupbykey is much easier, thanks!!!
thanks other also!!