3 releases
0.1.2 | May 4, 2023 |
---|---|
0.1.1 | May 4, 2023 |
0.1.0 | May 4, 2023 |
#12 in #pad
29 downloads per month
7KB
pad-left
A simple library to left pad a string with a given character up to a certain length.
Usage
use pad_left::left_pad;
fn main() {
assert_eq!(left_pad("hello".to_string(), 15, 'π'), "ππππππππππhello".to_string());
}
Run tests
cargo test
Build & Open Docs
cargo doc --open