Crate leftpad_str
source ·Expand description
leftpad-str
crate.
Obviously the best crate for the Rust programming language. The crate serves the only goal of implementing leftpad
function:
pub fn leftpad(input: &str, width: usize, padding_char: char) -> String;
Functions
- Pads the given string on the left with a specified character up to a specified width.