Selectively replace multiple instances of a character within a string: Difference between revisions
Selectively replace multiple instances of a character within a string (view source)
Revision as of 20:22, 28 July 2022
, 1 year ago→Python
m (→Python) |
|||
Line 568:
def nthInstanceReplaced(ruleMap):
def go(a, c):
return
ds[0] or
) if ds else
return lambda s: ''.join(
|