Logo

Programming-Idioms

History of Idiom 63 > diff from v4 to v5

Edit summary for version 5 by :

Version 4

2015-07-31, 19:33:28

Version 5

2015-08-20, 11:40:21

Idiom #63 Replace fragment of a string

Assign to x2 the value of string x with all occurrences of y replaced by z.

Idiom #63 Replace fragment of a string

Assign to x2 the value of string x with all occurrences of y replaced by z.

Code
let x2=x.replace(&y,&z).to_string();