I am trying to formulate a regular expression that identifies lines that begin and end with "B" but also have an odd number of letters in total. So far I have the following:
Lines starting and ending with B:
^B.*B$
I'm not sure how to get it so that it accepts an odd number of letters. For even numbers, this is easy:
^B(..)*B$
But the odd one throws me a little
source share