Matching by Digit Rule
There is an Excel file that teaches how to perform the Matching by Digit Rule operation.
Excel Matching By Digit Rule
Capturing specific digit patterns in mixed letter-number codes is accomplished through a highly practical method. Additionally, the REGEXTEST function allows regular expression patterns to be applied directly within cells. Thus, conditions such as the first digit being even and the last digit being odd can be checked with a single formula. However, this method is only supported in the Excel 365 version. Consequently, by combining FILTER and REGEXTEST, codes matching the rule are automatically filtered out.
Hope it is useful.