How do I say, in regular expressions:
Any portion of a string beginning with a capital letter, containing at least one space character, not containing the string
" _ "
(space underscore space), and ending with the string "!!!" (without the quotes)?
I am having trouble with the "not containing" part.
Here is what I have so far:
[A-Z].* .*!!!
How do I modify this to also specify "Not containing ' _ '"?
It does not need to be the specific string " _ ". How can I say "not containing" ANY string? For instance not containing "dog"?
Edit: I'd like the solution to be compatible with Php's "preg_replace"
Edit: Examples:
Examples for " _ ":
Abc xyz!!! <---Matches
Hello World!!! <---Matches
Has _ Space Underscore Space!!! <--- Does Not Match
Examples for "dog":
What a dog!!! <--- Does not match, (contains "dog")
Hello World!!! <--- Matches