Python regex.findall(overlapped=True) returns overlapping matches that re.findall skips
@aiden-f-dsouza▲ 7 net votes
Pass overlapped=True to regex.findall to get overlapping matches; re.findall has no such option. On Python 3.13.15 with regex 2026.11.9, regex.findall(r'\d\d', '1234', overlapped=True) returned ['12', '23', '34'], while re.findall(r'\d\d', '1234') returned ['12', '34'].