pub fn replace(s: &String, target: &str, insert: &str) -> String {
        let mut source = s.clone();
        while let Some(i) = source.find(target) {
            source.replace_range(i..i + len(&target.to_string()), insert);
        }
        source
    }
/*
    replaces all target str in String with insert str
    */
replaces all target str in String with insert str
replaces all target str in String with insert str
pub fn replace(s: &String, target: &str, insert: &str) -> String {
        let mut source = s.clone();
        while let Some(i) = source.find(target) {
            source.replace_range(i..i + len(&target.to_string()), insert);
        }
        source
    }
pub fn replace ( s : & String , target : & str , insert : & str ) -> String { let mut source = s . clone ( ) ; while let Some ( i ) = source . find ( target ) { source . replace_range ( i .. i + len ( & target . to_string ( ) ) , insert ) ; } source }
replaces all target str in String with insert str
replaces all target str in String with insert str
s
&String
target
&str
insert
&str
s
&String
target
&str
insert
&str