Replacing elements of a list

Feb 16, 2010 at 12:03pm

Replacing elements of a list

Hi All,

Is there an object that makes it simple to replace the nth element of a list with another value.

I’m currently using zl slice and join to achieve the desired function but was wondering if there is simpler method. Almost like a ‘zl replace’ function


Feb 16, 2010 at 12:16pm

Take another look in the help file of zl: giving zl nth a second argument does just that:

– Pasted Max Patch, click to expand. –
Feb 16, 2010 at 1:40pm

Thank you, this is exactly what I needed.



You must be logged in to reply to this topic.