<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                合規國際互聯網加速 OSASE為企業客戶提供高速穩定SD-WAN國際加速解決方案。 廣告
                ### 不用 re.VERBOSE 現在你可能注意到正則表達式的表示是十分緊湊,但它們非常不好讀。中度復雜的 REs 可以變成反斜杠、圓括號和元字符的長長集合,以致于使它們很難讀懂。 在這些 REs 中,當編譯正則表達式時指定 re.VERBOSE 標志是有幫助的,因為它允許你可以編輯正則表達式的格式使之更清楚。 re.VERBOSE 標志有這么幾個作用。在正則表達式中不在字符類中的空白符被忽略。這就意味著象 dog | cat 這樣的表達式和可讀性差的 dog|cat 相同,但 [a b] 將匹配字符 "a"、"b" 或 空格。另外,你也可以把注釋放到 RE 中;注釋是從 "#" 到下一行。當使用三引號字符串時,可以使 REs 格式更加干凈: ``` #!python pat = re.compile(r""" \s* # Skip leading whitespace (?P<header>[^:]+) # Header name \s*?: # Whitespace, and a colon (?P<value>.*?) # The header's value -- *? used to # lose the following trailing whitespace \s*$ # Trailing whitespace to end-of-line """, re.VERBOSE) ``` 這個要難讀得多: ``` #!python pat = re.compile(r"\s*(?P<header>[^:]+)\s*:(?P<value>.*?)\s*$") ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看