I understood that moldy gave just an example, and that the list could be wide.
The solution I gave permits a list of any number of elements, in the case of 50 elements, for ex. it would be difficult to make the replacements one by one.
And the solution is relatively simple, the function has only 3 lines (one line is optional)
|