Test, validate and match regular expressions
This regular expression matches text enclosed between two dollar signs on a single line, utilizing a lazy quantifier to find the shortest possible match. It is commonly used to extract inline LaTeX math equations, such as $x^2 + y^2 = r^2$. The global and multiline flags ensure it finds all non-overlapping occurrences across multiple lines of text.