almost complete tree to string translator