✅ Regex pattern to match unique words each with 3 unique characters

Given a multiline input text:

abc
aaaa
bcde
acd
abc
abc
xyz

I am looking for a regex pattern that matches unique words each consists of exactly 3 unique characters.
The expected output:
acd
xyz


Edit:
For new visitors, this question can actually be solved with negative lookbehind and negative lookahead.
If you are in hurry, you can jump to https://discord.com/channels/143867839282020352/1204500978741673994/1204519081663926304
and return again to this message ✅ Regex pattern to match unique words each with 3 unique characters in the future.
I may update with the solution. 🙂
Was this page helpful?