| Crates.io | rightpad-str |
| lib.rs | rightpad-str |
| version | 6.6.6 |
| created_at | 2023-06-08 13:43:27.706751+00 |
| updated_at | 2023-06-08 13:43:27.706751+00 |
| description | Obviously the second best crate (after `leftpad-str`) for the Rust programming language. The crate serves the only goal of implementing `rightpad` function. |
| homepage | |
| repository | https://github.com/abs0luty/rightpad |
| max_upload_size | |
| id | 885503 |
| size | 534,017 |
rightpad-str crate.Obviously the second best crate (after leftpad-str) for the Rust programming language. The crate serves the only goal of implementing rightpad function:
pub fn rightpad(input: &str, width: usize, padding_char: char) -> String;
assert_eq!(rightpad("hello", 8, '*'), "hello***");
assert_eq!(rightpad("rust", 6, ' '), "rust ");