<p>I am battling regular expressions now as I type. </p>

<p>I would like to determine a pattern for the following example file: <code>b410cv11_test.ext</code>. I want to be able to do a search for files that match the pattern of the example file aforementioned. Where do I start (so lost and confused) and what is the best way of arriving at a solution that best matches the file pattern? Thanks in advance. </p>

<p><strong><em>Further clarification of question:</em></strong></p>

<p>I would like the pattern to be as follows: must start with 'b', followed by three digits, followed by 'cv', followed by two digits, then an underscore, followed by 'release', followed by .'ext'</p>

To avoid confusion, read the following, in order.
First, you have the
glob
module, which handles file name regular expressions just like the Windows and unix shells.
Second, you have the
fnmatch
module, which just does pattern matching using the unix shell rules.
Third, you have the
re
module, which is the complete set of regular expressions.
Then ask another, more specific question.