On Apr 11, 8:12 pm, Lie Ryan <lie.1...@gmail.com> wrote: > In the first case, *python* will unescape the string literal '\x62' into > letters 'b'. In the second case, python will unescape the double > backslash '\\' into a single slash '\' and *regex* will unescape the > single-slash-62 into 'b'. In the third case, *python* will unescape > double backslash '\\' into single-slash '\' and byte-string-62 '\x62' to > letter-b 'b', and regex received it as 'a\bc', which interpreted as a > special character to regex: > """ > \b Matches the empty string, but only at the start or end of a word. > """
ah, brilliant! yes. thank-you very much! andrew -- http://mail.python.org/mailman/listinfo/python-list