http://www.perlmonks.org?node_id=1018491

Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Input https://www.abc.com.wi.pr.com/ https://www.abc.com/ https://www.def.com.wi.pr.com/ https://www.wt.com.wi.pr.com/

There are many URL's but we should not match with the string (wt).

https?://(www.)?(abc|def).com[^/]*/?$

Hard coding works but there are many names which is not possible,

Trying to use the regex something like this but no luck :(
https?://(www.)?(.*)(?!wt).com[^/]*/?$
Please help me.