0

I tried to use re.findall('^(?!a)b', 'xyzabbcdebt') to select all b not starts with a.

I expect to have ['b', 'b'].

However, it gives an empty array.

What is the correct regex?

Chan
  • 3,605
  • 9
  • 29
  • 60

0 Answers0