leftpad-str 9.9.9

Obviously the best crate for the Rust programming language. The crate serves the only goal of implementing `leftpad` function.
Documentation
  • Coverage
  • 100%
    2 out of 2 items documented1 out of 1 items with examples
  • Size
  • Source code size: 539.82 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 1.04 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Links
  • abs0luty/leftpad
    3 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • abs0luty

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;

Examples

assert_eq!(leftpad("hello", 8, '*'), "***hello");
assert_eq!(leftpad("rust", 6, ' '), "  rust");