On Friday, February 24, 2017 at 2:41:58 PM UTC-8, Erik wrote:
> On 24/02/17 22:18, kar wrote:
> > Thanks, what is the idea behind storing the keys and values in a list, I
> > assume looking up for a value in a map is faster getting the value from the
> > list.
>
> What do you not understand? MRA
I have a task to search for multiple patterns in incoming string and replace
with matched patterns, I'm storing all pattern as keys in dict and replacements
as values, I'm using regex for compiling all the pattern and using the sub
method on pattern object for replacement. But the problem I have