String preprocessing and minus operator detection