break a variable length list at a specific element
"Peter P." <[email protected]>
| Newsgroups | gmane.comp.multimedia.puredata.general |
|---|---|
| Message-ID | <[email protected]> |
Hi list, I am having lists with a variable number of items and I want to break them up two lists dependent on the presence of a specific item. I can't seem to understand how to do it though. Here's a quick example of what I mean: 1 2 3 4 5 6 look for the number 4 and output two lists (at separate outlets) which are before and after that number 4, giving: 1 2 3 and 5 6 respectively I'd need the solution to work for lists of other lengths as well, i.e. 55 66 77 88 4 102 -33 should be broken up into 55 66 77 88 and 102 -33 alike. I tried [route] and [list] objects but can't get them to do what I want. thanks! P --- [email protected] - the Pure Data mailinglist https://lists.iem.at/hyperkitty/list/[email protected]/message/7EF2SASANM67WTX766GIKCN5OIR64PXN/ To unsubscribe send an email to [email protected] mailing list UNSUBSCRIBE and account-management -> https://lists.iem.at/