I found a regex not to match a word from this question Regular expression to match a line that doesn't contain a word? .
u(?!i) will match a word with u not followed by i. The answer says that it checks if each character is not followed by hede. So shouldn't the regex be /^(.(?!hede))*$/. It works for words containing hede but not starting with it. Why do they use /^((?!hede).)*$/ . Whats the difference between the position of the dot. I used re=debug but couldn't still get the meaning
 
     
     
     
    