Making a list by summing values



This is my first post here. I am trying to make a list of values that are generated by summing together values in another list.

I want to place a collection of families that have the parameter “width.” I am reading the width parameter of each type into a list. So I have all of these values, but they vary as you might expect, so the list is something like:

[0] 7.00

[1] 6.00

[2] 7.00

[3] 5.50


What I want to do is place the first family at 0, then the next one at 7, the next at 13, then 20.

So I want to add the width of the previously placed one to the x value of the next one, then repeat till they are all placed. I am trying to get a consistent “padding” in between elements. I have it working just fine to place them using a sequence where the spacing is equal, but this unequal spacing using the “padding” idea is not going well for me. I am assuming I need to do something with GetItemAtIndex and then add to the previous some how, but I can’t seem to get there.

Any suggestions?

Thanks very much!








Hi Paul,

Have a look at the following discussions:


I’ll give those a try and let you know how I make out. Thanks.


Hi Dimitar: Thanks for those links. I used the second example and the List.Scan did the trick! Thanks so much.