preprpcess strings