in reply to string concatenation, which way is better?
In this case it probably makes little difference; it's a matter of personal preference. In the general case you sometimes need the exact-formatting control that sprintf() provides. Depends on the circumstances.