[issue46945] Quantifier and Expanded Regex Expression Gives Different Results

2022-03-07 Thread Eric V. Smith
Change by Eric V. Smith : -- components: +Regular Expressions -Library (Lib) nosy: +ezio.melotti, mrabarnett ___ Python tracker ___

[issue46945] Quantifier and Expanded Regex Expression Gives Different Results

2022-03-07 Thread Vedran Čačić
Vedran Čačić added the comment: Confirmed. On Python 3.10.2, >>> re.findall(r"(((\w)+\w*\3){2}|(\w)+(?=\w*\4)\w*(?!\4)(\w)\w*\5)\w*",'alabama') [] yet https://regex101.com/r/uT8gag/1 (with "Python" selected) says it should match. -- nosy: +veky

[issue46945] Quantifier and Expanded Regex Expression Gives Different Results

2022-03-07 Thread Vivian D
New submission from Vivian D : Here are the steps that I went through to test my regular expressions in my command prompt (a file attachment shows this as well). I am using Windows 11, version 21H2: >>> import re >>> regex = r"(((\w)+\w*\3){2}|(\w)+(?=\w*\4)\w*(?!\4)(\w)\w*\5)\w*" >>>