i need a regex that allow words which have no hyphen inside them. For example, in a string " non-word sentence " it should only match "sentence". I wrote:
"\b(?!\w+[-]\w+)\w+"
and it fails:
It matches not only "sentence" but also "word".
How to make it ignore words with hyphens inside?