pub fn replace_char(string: &str, index: i32, replacement: char) -> String
Expand description
Replaces the character at the given index and returns the string.
ยงExample:
let input: &str = "Hello, World!";
let result: String = funny_string::replace_char(input, 3, 'X');
// result now contains the string "HelXo, World!"