Doing text processing in Python, trying to match <brackets> in the output. The inside can contain any character, but if there are numbers the brackets shall not match if there is more than 1 single digit number. For instance...
< 1? >
<12>
<hot 198663 , ? ... @ key \n 6>
...shall↑match, while...
<0 0>
<9653, 8 test 6>
<18str 500 ing 4. 3 – 6>
...shall↑not.
I have tried with something like <(?:\d{1}|\d{2,}|[^\d])>, but it doesn’t really do it.