implementation by string