How to add a negative lookahead to my regular expression?

I'm not good with negative lookahead. What's wrong with this solution? I solved it myself, then I asked ChatGPT to solve it, and it came up with the same solution.

1 Like