0

How would I write a Java regular expression that matches everything except the following string?

abc123DEF@domain.com

(?!abc123DEF@domain.com) doesn't work.

Melanie
  • 1
  • 1

1 Answers1

0

Just a simple change of your regex:

(?!abc123DEF@domain.com).*

it works.

Alchemist
  • 1
  • 1