Best way to "replace" an element of an immutable list

Very elegant piece of code… thanks👍🏼

1 Like