another method without StringBuilder