Create sublist each x values

Hi guys,

I’m trying to import XML data to Revit but i have a problem during the process. I want to create a sublist each x values. I tried several nodes such as List.Sublists, List Flatten.
The picture below show what i want (circle in blue) and what i have now (in red). In this example i want a sublist every 2 values, but in other cases it can be more than 2. I hope i was clear enough.


list.chop? is.Number etc? hard to tell

@Einar_Raknes once learned me this:

Not sure what you mean that in other cases you need more than 2. Will it occur at the same time, like you’ll want sublist containing 2 and 3 etc items at once?

1 Like

Thanks i forgot list chop node. Work perfectly.

jostein_olsen Your solution works too. Even if i want more than 2 i mean a list of 3 or more i just have to change the ranges input 0…1 to 0…2 if i want 3. Thanks for your help.

Problem solved