Writing an algebra for the implode semantics.