use contain::SimpleContainer;
fn append_thing<'a>(container: &'a SimpleContainer<String>, s: &str) -> &'a str {
container.put(format!("{}thing", s))
}
fn main() {
let container = SimpleContainer::new();
let a = append_thing(&container, "some");
let b = append_thing(&container, "a ");
let c = append_thing(&container, "that ");
assert_eq!(a, "something");
assert_eq!(b, "a thing");
assert_eq!(c, "that thing");
assert_eq!(container.count(), 3);
}