Build, test, and debug regular expressions
This regex splits a Unix-style file path into two capture groups: the first greedily matches everything up to the last forward slash (the directory portion), and the second captures the filename after it. For example, '/home/user/docs/file.txt' yields '/home/user/docs' and 'file.txt'. Commonly used for extracting filenames or directory paths from full paths in scripts, log parsing, and file processing tasks.