Populating lists with duplicate items - Urgent help needed
Hey guys, I'm looking for help with a list-related issue.
I need to create a list to control a bline/line object. This list will contain target values and time durations - forget the target values for now. To create the list, I want to use the combination of two other lists: one contains time values and the other contains the number of their occurrences in order. E.g.:
time values: (2000, 1000, 500, 250)
occurrences: (2, 3, 2, 4)
My desired result: (2000, 2000, 1000, 1000, 1000, 500, 500, 250, 250, 250, 250)
I've been looking at the zl modes but I couldn't seem to find anything related to specify the number of occurrences of an item.
Any pointers would be greatly appreciated.
Thanks in advance.
Benji
Hi Benji,
Zl-objects rarely work on their own, usually you will need several to solve your problem (as in this case)
Luvulongtime!
Thanks for the input luvulongtime!
It's not homework, it's part of a patch for an algorithmic composition:)
Good :)