for suppose if I have a list of unique elements,
list = [.......,'a','b','c',.....]
How to replace 'a','b' with 'd' such that it results,
list = [.....,'d','c'.....]
without any loops.
I have tried doing this, but it's not working.
list[list.index('a'):list.index('b')] = 'd'