building strings from a hash