Skip to content

Instantly share code, notes, and snippets.

View miraclx's full-sized avatar
🦀
Pirate of the Crab-ibean

Miraculous Owonubi miraclx

🦀
Pirate of the Crab-ibean
View GitHub Profile
@miraclx
miraclx / playground.rs
Last active October 10, 2022 05:10 — forked from rust-play/playground.rs
Human List
fn human_list<I, T>(i: I) -> String
where
I: Iterator<Item = T>,
T: AsRef<str>,
{
let mut items = i.peekable();
let mut s = match items.next() {
Some(s) => s.as_ref().to_owned(),
None => return String::new(),
};