Replace x value into y value in string text. Example text='Hello World' x='World', y='Universe' result='Hello Universe'.
So we can use the ans trick again ?
But we can't use something like :
function text = Replace(text,x,y)
tructruc(text,x,y)
Strange no ?
regexprep doesn't modify directly str
For example :
str='Jean'
regexprep(str,'e','a')
ans='Jaan'
but str is always = 'Jean'
Well this is a function in R2016b.No wonder no others have used it.