Build, test, and debug regular expressions
This regex matches dates in both Brazilian (DD/MM/YYYY or DD-MM-YY) and US (MM/DD/YYYY or MM-DD-YY) formats, accepting slashes or hyphens as separators. It also supports two-digit or four-digit years. Useful for validating and extracting date inputs in multilingual or international applications, log files, and user forms where both conventions may appear. The pattern ensures the date structure has either day first or month first, making it flexible for different regional input styles.