removes all words less than 3 chars.
But how to reset this demo vise versa ? to remove all words NOT EXACTLY EQUAL 3 chars ?
We can catch word where exactly 3 chars by
but how to tell regex – remove all other words what are NOT equal to 3 ?
So in regex demo ref above should leave only word ‘and’
Source: Ask PHP