Assuming extensions are up to 4 characters long (therefore file names such as mr.smith are not considered to have an extension, but mr.smith.doc and mr.smith.html considered to have extensions):
^.*[^.]{5}$
No need to capture a group, as the whole expression is what you want - i.e. group 0.
Bohemian
source share