performance: use StringBuilder instead of String concatenation