{"id":960428,"date":"2024-12-27T03:49:40","date_gmt":"2024-12-26T19:49:40","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/960428.html"},"modified":"2024-12-27T03:49:42","modified_gmt":"2024-12-26T19:49:42","slug":"python%e5%a6%82%e4%bd%95%e7%ad%9b%e9%80%89%e8%bf%9e%e7%bb%ad%e6%95%b0%e5%ad%97","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/960428.html","title":{"rendered":"python\u5982\u4f55\u7b5b\u9009\u8fde\u7eed\u6570\u5b57"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25102937\/febda3d6-47c6-49a8-acfc-52063e6816b0.webp\" alt=\"python\u5982\u4f55\u7b5b\u9009\u8fde\u7eed\u6570\u5b57\" \/><\/p>\n<p><p> <strong>\u5728Python\u4e2d\u7b5b\u9009\u8fde\u7eed\u6570\u5b57\uff0c\u53ef\u4ee5\u901a\u8fc7\u4f7f\u7528\u6b63\u5219\u8868\u8fbe\u5f0f\u3001\u5217\u8868\u89e3\u6790\u3001\u5faa\u73af\u904d\u5386\u7b49\u65b9\u6cd5\u5b9e\u73b0\u3002\u6b63\u5219\u8868\u8fbe\u5f0f\u63d0\u4f9b\u4e86\u4e00\u79cd\u5f3a\u5927\u800c\u7075\u6d3b\u7684\u65b9\u5f0f\u6765\u8bc6\u522b\u8fde\u7eed\u6570\u5b57\u5e8f\u5217\uff0c\u800c\u5217\u8868\u89e3\u6790\u548c\u5faa\u73af\u904d\u5386\u5219\u63d0\u4f9b\u4e86\u66f4\u52a0\u76f4\u89c2\u7684\u903b\u8f91\u5b9e\u73b0\u3002\u672c\u6587\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u8fd9\u4e9b\u65b9\u6cd5\uff0c\u5e76\u63d0\u4f9b\u793a\u4f8b\u4ee3\u7801\u5e2e\u52a9\u7406\u89e3\u3002<\/strong><\/p>\n<\/p>\n<p><p>\u5728Python\u4e2d\uff0c\u5904\u7406\u548c\u7b5b\u9009\u8fde\u7eed\u6570\u5b57\u7684\u4efb\u52a1\u53ef\u4ee5\u901a\u8fc7\u591a\u79cd\u65b9\u6cd5\u6765\u5b9e\u73b0\u3002\u4ee5\u4e0b\u662f\u4e00\u4e9b\u5e38\u7528\u7684\u7b56\u7565\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u6b63\u5219\u8868\u8fbe\u5f0f\u65b9\u6cd5\uff1a<\/strong> \u6b63\u5219\u8868\u8fbe\u5f0f\uff08Regular Expressions\uff09\u662f\u4e00\u79cd\u5f3a\u5927\u7684\u5de5\u5177\uff0c\u7528\u4e8e\u5728\u5b57\u7b26\u4e32\u4e2d\u8fdb\u884c\u6a21\u5f0f\u5339\u914d\u3002\u901a\u8fc7\u6b63\u5219\u8868\u8fbe\u5f0f\uff0c\u6211\u4eec\u53ef\u4ee5\u8f7b\u677e\u627e\u5230\u8fde\u7eed\u7684\u6570\u5b57\u5e8f\u5217\u3002Python\u7684<code>re<\/code>\u6a21\u5757\u652f\u6301\u6b63\u5219\u8868\u8fbe\u5f0f\u64cd\u4f5c\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u5217\u8868\u89e3\u6790\u548c\u96c6\u5408\u65b9\u6cd5\uff1a<\/strong> \u901a\u8fc7\u5217\u8868\u89e3\u6790\uff0c\u6211\u4eec\u53ef\u4ee5\u5feb\u901f\u8fc7\u6ee4\u51fa\u7b26\u5408\u6761\u4ef6\u7684\u5143\u7d20\u3002\u540c\u65f6\uff0c\u4f7f\u7528\u96c6\u5408\u53ef\u4ee5\u5e2e\u52a9\u6211\u4eec\u5904\u7406\u548c\u7b5b\u9009\u51fa\u72ec\u7279\u7684\u8fde\u7eed\u6570\u5b57\u5e8f\u5217\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u5faa\u73af\u904d\u5386\u65b9\u6cd5\uff1a<\/strong> \u5bf9\u4e8e\u4e00\u4e9b\u7b80\u5355\u7684\u4efb\u52a1\uff0c\u53ef\u4ee5\u4f7f\u7528\u5faa\u73af\u904d\u5386\u7684\u65b9\u6cd5\u6765\u9010\u4e2a\u68c0\u67e5\u6570\u5b57\u662f\u5426\u8fde\u7eed\u3002\u8fd9\u79cd\u65b9\u6cd5\u867d\u7136\u76f4\u89c2\uff0c\u4f46\u5728\u5927\u578b\u6570\u636e\u96c6\u4e0a\u53ef\u80fd\u4e0d\u5982\u6b63\u5219\u8868\u8fbe\u5f0f\u9ad8\u6548\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u63a5\u4e0b\u6765\uff0c\u6211\u4eec\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u8fd9\u4e9b\u65b9\u6cd5\u53ca\u5176\u5b9e\u73b0\u3002<\/p>\n<\/p>\n<p><h2>\u4e00\u3001\u6b63\u5219\u8868\u8fbe\u5f0f\u65b9\u6cd5<\/h2>\n<\/p>\n<p><p>\u6b63\u5219\u8868\u8fbe\u5f0f\u662f\u4e00\u79cd\u7528\u4e8e\u63cf\u8ff0\u5b57\u7b26\u6a21\u5f0f\u7684\u8bed\u6cd5\u89c4\u5219\u3002Python\u4e2d\u901a\u8fc7<code>re<\/code>\u6a21\u5757\u53ef\u4ee5\u5b9e\u73b0\u6b63\u5219\u8868\u8fbe\u5f0f\u5339\u914d\u64cd\u4f5c\u3002<\/p>\n<\/p>\n<p><h3>1. \u4f7f\u7528\u6b63\u5219\u8868\u8fbe\u5f0f\u7b5b\u9009\u8fde\u7eed\u6570\u5b57<\/h3>\n<\/p>\n<p><p>\u5728Python\u4e2d\uff0c\u6211\u4eec\u53ef\u4ee5\u4f7f\u7528<code>re<\/code>\u6a21\u5757\u4e2d\u7684<code>findall()<\/code>\u51fd\u6570\u6765\u67e5\u627e\u5b57\u7b26\u4e32\u4e2d\u6240\u6709\u5339\u914d\u7ed9\u5b9a\u6b63\u5219\u8868\u8fbe\u5f0f\u7684\u5b50\u4e32\u3002\u5bf9\u4e8e\u7b5b\u9009\u8fde\u7eed\u6570\u5b57\uff0c\u6211\u4eec\u53ef\u4ee5\u4f7f\u7528<code>\\d{n,}<\/code>\u683c\u5f0f\u7684\u6b63\u5219\u8868\u8fbe\u5f0f\uff0c\u5176\u4e2d<code>n<\/code>\u8868\u793a\u81f3\u5c11n\u4e2a\u8fde\u7eed\u6570\u5b57\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import re<\/p>\n<p>def find_consecutive_numbers(text, min_length=2):<\/p>\n<p>    pattern = r&#39;\\d{&#39; + str(min_length) + &#39;,}&#39;<\/p>\n<p>    matches = re.findall(pattern, text)<\/p>\n<p>    return matches<\/p>\n<h2><strong>\u793a\u4f8b<\/strong><\/h2>\n<p>text = &quot;abc12345def678ghi90123jkl456&quot;<\/p>\n<p>consecutive_numbers = find_consecutive_numbers(text, 3)<\/p>\n<p>print(consecutive_numbers)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>2. \u6b63\u5219\u8868\u8fbe\u5f0f\u7684\u4f18\u52bf<\/h3>\n<\/p>\n<p><p>\u6b63\u5219\u8868\u8fbe\u5f0f\u7684\u4f18\u52bf\u5728\u4e8e\u5176\u5f3a\u5927\u7684\u6a21\u5f0f\u5339\u914d\u80fd\u529b\u548c\u7b80\u6d01\u7684\u8bed\u6cd5\uff0c\u4f7f\u5f97\u590d\u6742\u7684\u5b57\u7b26\u4e32\u64cd\u4f5c\u53d8\u5f97\u7b80\u5355\u3002\u6b64\u5916\uff0c\u6b63\u5219\u8868\u8fbe\u5f0f\u8fd8\u652f\u6301\u591a\u79cd\u5339\u914d\u89c4\u5219\u548c\u9009\u9879\uff0c\u53ef\u4ee5\u7075\u6d3b\u8c03\u6574\u4ee5\u6ee1\u8db3\u4e0d\u540c\u9700\u6c42\u3002<\/p>\n<\/p>\n<p><h2>\u4e8c\u3001\u5217\u8868\u89e3\u6790\u548c\u96c6\u5408\u65b9\u6cd5<\/h2>\n<\/p>\n<p><p>\u5217\u8868\u89e3\u6790\u662f\u4e00\u79cd\u7b80\u6d01\u7684\u521b\u5efa\u5217\u8868\u7684\u65b9\u5f0f\uff0c\u800c\u96c6\u5408\u53ef\u4ee5\u7528\u4e8e\u53bb\u91cd\u3002<\/p>\n<\/p>\n<p><h3>1. \u4f7f\u7528\u5217\u8868\u89e3\u6790\u7b5b\u9009\u8fde\u7eed\u6570\u5b57<\/h3>\n<\/p>\n<p><p>\u5217\u8868\u89e3\u6790\u662f\u4e00\u79cd\u7b80\u5316\u4ee3\u7801\u7684\u65b9\u5f0f\uff0c\u901a\u8fc7\u5728\u4e00\u884c\u4e2d\u5b9e\u73b0for\u5faa\u73af\u548c\u6761\u4ef6\u5224\u65ad\u6765\u751f\u6210\u5217\u8868\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">def find_consecutive_numbers_via_list(text, min_length=2):<\/p>\n<p>    numbers = [text[i:j] for i in range(len(text)) for j in range(i + min_length, len(text) + 1) if text[i:j].isdigit()]<\/p>\n<p>    return [num for num in numbers if len(num) &gt;= min_length]<\/p>\n<h2><strong>\u793a\u4f8b<\/strong><\/h2>\n<p>text = &quot;abc12345def678ghi90123jkl456&quot;<\/p>\n<p>consecutive_numbers = find_consecutive_numbers_via_list(text, 3)<\/p>\n<p>print(consecutive_numbers)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>2. \u4f7f\u7528\u96c6\u5408\u53bb\u91cd<\/h3>\n<\/p>\n<p><p>\u5728\u4e00\u4e9b\u60c5\u51b5\u4e0b\uff0c\u6211\u4eec\u53ef\u80fd\u9700\u8981\u786e\u4fdd\u7b5b\u9009\u51fa\u7684\u8fde\u7eed\u6570\u5b57\u5e8f\u5217\u662f\u72ec\u4e00\u65e0\u4e8c\u7684\u3002\u6b64\u65f6\uff0c\u53ef\u4ee5\u4f7f\u7528\u96c6\u5408\u6765\u53bb\u91cd\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">def unique_consecutive_numbers(text, min_length=2):<\/p>\n<p>    numbers = set(find_consecutive_numbers_via_list(text, min_length))<\/p>\n<p>    return list(numbers)<\/p>\n<h2><strong>\u793a\u4f8b<\/strong><\/h2>\n<p>text = &quot;abc12345def678ghi90123jkl456&quot;<\/p>\n<p>unique_numbers = unique_consecutive_numbers(text, 3)<\/p>\n<p>print(unique_numbers)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h2>\u4e09\u3001\u5faa\u73af\u904d\u5386\u65b9\u6cd5<\/h2>\n<\/p>\n<p><p>\u5faa\u73af\u904d\u5386\u662f\u4e00\u79cd\u8f83\u4e3a\u57fa\u7840\u7684\u5b9e\u73b0\u65b9\u5f0f\uff0c\u901a\u8fc7\u9010\u4e2a\u68c0\u67e5\u5b57\u7b26\u4e32\u4e2d\u7684\u5b57\u7b26\u5b9e\u73b0\u7b5b\u9009\u3002<\/p>\n<\/p>\n<p><h3>1. \u57fa\u672c\u5faa\u73af\u904d\u5386\u5b9e\u73b0<\/h3>\n<\/p>\n<p><p>\u901a\u8fc7\u5faa\u73af\u904d\u5386\uff0c\u6211\u4eec\u53ef\u4ee5\u9010\u4e2a\u68c0\u67e5\u5b57\u7b26\u662f\u5426\u4e3a\u6570\u5b57\uff0c\u5e76\u5224\u65ad\u5176\u662f\u5426\u8fde\u7eed\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">def find_consecutive_numbers_via_loop(text, min_length=2):<\/p>\n<p>    consecutive_numbers = []<\/p>\n<p>    current_number = &quot;&quot;<\/p>\n<p>    for char in text:<\/p>\n<p>        if char.isdigit():<\/p>\n<p>            current_number += char<\/p>\n<p>        else:<\/p>\n<p>            if len(current_number) &gt;= min_length:<\/p>\n<p>                consecutive_numbers.append(current_number)<\/p>\n<p>            current_number = &quot;&quot;<\/p>\n<p>    # \u68c0\u67e5\u6700\u540e\u4e00\u4e2a\u6570\u5b57\u5e8f\u5217<\/p>\n<p>    if len(current_number) &gt;= min_length:<\/p>\n<p>        consecutive_numbers.append(current_number)<\/p>\n<p>    return consecutive_numbers<\/p>\n<h2><strong>\u793a\u4f8b<\/strong><\/h2>\n<p>text = &quot;abc12345def678ghi90123jkl456&quot;<\/p>\n<p>consecutive_numbers = find_consecutive_numbers_via_loop(text, 3)<\/p>\n<p>print(consecutive_numbers)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>2. \u5faa\u73af\u65b9\u6cd5\u7684\u9002\u7528\u573a\u666f<\/h3>\n<\/p>\n<p><p>\u5faa\u73af\u904d\u5386\u65b9\u6cd5\u9002\u7528\u4e8e\u7b80\u5355\u7684\u4efb\u52a1\uff0c\u7279\u522b\u662f\u5728\u5904\u7406\u8f83\u77ed\u5b57\u7b26\u4e32\u6216\u5bf9\u6027\u80fd\u8981\u6c42\u4e0d\u9ad8\u7684\u60c5\u51b5\u4e0b\u3002\u5176\u5b9e\u73b0\u8f83\u4e3a\u76f4\u89c2\uff0c\u4fbf\u4e8e\u7406\u89e3\u548c\u4fee\u6539\u3002<\/p>\n<\/p>\n<p><h2>\u56db\u3001\u7ed3\u5408\u591a\u79cd\u65b9\u6cd5<\/h2>\n<\/p>\n<p><p>\u5728\u5b9e\u9645\u5e94\u7528\u4e2d\uff0c\u6211\u4eec\u53ef\u4ee5\u6839\u636e\u5177\u4f53\u9700\u6c42\uff0c\u5c06\u591a\u79cd\u65b9\u6cd5\u7ed3\u5408\u4f7f\u7528\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u5148\u4f7f\u7528\u6b63\u5219\u8868\u8fbe\u5f0f\u63d0\u53d6\u6570\u5b57\u5e8f\u5217\uff0c\u518d\u901a\u8fc7\u96c6\u5408\u53bb\u91cd\uff0c\u6700\u540e\u4f7f\u7528\u5217\u8868\u89e3\u6790\u8fdb\u884c\u8fdb\u4e00\u6b65\u7684\u5904\u7406\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">def comprehensive_find_consecutive_numbers(text, min_length=2):<\/p>\n<p>    # \u4f7f\u7528\u6b63\u5219\u8868\u8fbe\u5f0f\u63d0\u53d6\u6570\u5b57\u5e8f\u5217<\/p>\n<p>    numbers = find_consecutive_numbers(text, min_length)<\/p>\n<p>    # \u4f7f\u7528\u96c6\u5408\u53bb\u91cd<\/p>\n<p>    unique_numbers = set(numbers)<\/p>\n<p>    # \u4f7f\u7528\u5217\u8868\u89e3\u6790\u8fdb\u884c\u8fdb\u4e00\u6b65\u5904\u7406<\/p>\n<p>    processed_numbers = [num for num in unique_numbers if len(num) &gt;= min_length]<\/p>\n<p>    return processed_numbers<\/p>\n<h2><strong>\u793a\u4f8b<\/strong><\/h2>\n<p>text = &quot;abc12345def678ghi90123jkl456&quot;<\/p>\n<p>comprehensive_numbers = comprehensive_find_consecutive_numbers(text, 3)<\/p>\n<p>print(comprehensive_numbers)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u901a\u8fc7\u7ed3\u5408\u591a\u79cd\u65b9\u6cd5\uff0c\u53ef\u4ee5\u5b9e\u73b0\u66f4\u9ad8\u6548\u3001\u66f4\u7075\u6d3b\u7684\u8fde\u7eed\u6570\u5b57\u7b5b\u9009\u3002<\/p>\n<\/p>\n<p><h2>\u4e94\u3001\u603b\u7ed3<\/h2>\n<\/p>\n<p><p>\u5728Python\u4e2d\uff0c\u7b5b\u9009\u8fde\u7eed\u6570\u5b57\u7684\u4efb\u52a1\u53ef\u4ee5\u901a\u8fc7\u591a\u79cd\u65b9\u6cd5\u5b9e\u73b0\uff0c\u5305\u62ec\u6b63\u5219\u8868\u8fbe\u5f0f\u3001\u5217\u8868\u89e3\u6790\u548c\u5faa\u73af\u904d\u5386\u7b49\u3002\u6b63\u5219\u8868\u8fbe\u5f0f\u63d0\u4f9b\u4e86\u5f3a\u5927\u7684\u6a21\u5f0f\u5339\u914d\u80fd\u529b\uff0c\u9002\u5408\u5904\u7406\u590d\u6742\u7684\u5b57\u7b26\u4e32\u64cd\u4f5c\uff1b\u5217\u8868\u89e3\u6790\u548c\u96c6\u5408\u53ef\u4ee5\u5728\u7b80\u5316\u4ee3\u7801\u7684\u540c\u65f6\u5b9e\u73b0\u53bb\u91cd\uff1b\u5faa\u73af\u904d\u5386\u5219\u9002\u5408\u7b80\u5355\u4efb\u52a1\u548c\u521d\u5b66\u8005\u7406\u89e3\u3002\u6839\u636e\u5177\u4f53\u9700\u6c42\uff0c\u9009\u62e9\u5408\u9002\u7684\u65b9\u6cd5\u6216\u5c06\u591a\u79cd\u65b9\u6cd5\u7ed3\u5408\u4f7f\u7528\uff0c\u53ef\u4ee5\u8fbe\u5230\u6700\u4f73\u6548\u679c\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u4f7f\u7528Python\u7b5b\u9009\u51fa\u8fde\u7eed\u7684\u6570\u5b57\uff1f<\/strong><br \/>\u5728Python\u4e2d\uff0c\u7b5b\u9009\u8fde\u7eed\u6570\u5b57\u53ef\u4ee5\u901a\u8fc7\u5217\u8868\u63a8\u5bfc\u548c\u5faa\u73af\u6765\u5b9e\u73b0\u3002\u9996\u5148\uff0c\u60a8\u9700\u8981\u4e00\u4e2a\u6570\u5b57\u5217\u8868\uff0c\u7136\u540e\u53ef\u4ee5\u901a\u8fc7\u6bd4\u8f83\u76f8\u90bb\u5143\u7d20\u6765\u68c0\u67e5\u5b83\u4eec\u662f\u5426\u8fde\u7eed\u3002\u5982\u679c\u60a8\u6709\u4e00\u4e2a\u5df2\u6392\u5e8f\u7684\u5217\u8868\uff0c\u53ef\u4ee5\u7b80\u5355\u5730\u904d\u5386\u5217\u8868\u5e76\u68c0\u67e5\u6bcf\u4e2a\u5143\u7d20\u4e0e\u4e0b\u4e00\u4e2a\u5143\u7d20\u4e4b\u95f4\u7684\u5dee\u503c\u662f\u5426\u4e3a1\u3002<\/p>\n<p><strong>\u6709\u54ea\u4e9bPython\u5e93\u53ef\u4ee5\u5e2e\u52a9\u7b5b\u9009\u8fde\u7eed\u6570\u5b57\uff1f<\/strong><br \/>\u867d\u7136\u539f\u751fPython\u53ef\u4ee5\u5b9e\u73b0\u7b5b\u9009\uff0c\u4f46\u4f7f\u7528\u5e93\u5982NumPy\u6216Pandas\u53ef\u4ee5\u66f4\u52a0\u9ad8\u6548\u3002NumPy\u63d0\u4f9b\u4e86\u6570\u7ec4\u64cd\u4f5c\u7684\u5f3a\u5927\u529f\u80fd\uff0c\u53ef\u4ee5\u8f7b\u677e\u5904\u7406\u548c\u7b5b\u9009\u8fde\u7eed\u7684\u6570\u5b57\u3002\u800cPandas\u5219\u63d0\u4f9b\u4e86\u6570\u636e\u6846\u67b6\u7684\u4fbf\u5229\u6027\uff0c\u5141\u8bb8\u60a8\u901a\u8fc7\u6761\u4ef6\u7b5b\u9009\u548c\u5206\u7ec4\u8f7b\u677e\u8bc6\u522b\u8fde\u7eed\u7684\u6570\u5b57\u5e8f\u5217\u3002<\/p>\n<p><strong>\u5982\u679c\u6211\u7684\u6570\u5b57\u5217\u8868\u5305\u542b\u4e0d\u8fde\u7eed\u7684\u6570\u5b57\uff0c\u5982\u4f55\u53ea\u63d0\u53d6\u8fde\u7eed\u7684\u90e8\u5206\uff1f<\/strong><br \/>\u53ef\u4ee5\u4f7f\u7528\u5faa\u73af\u548c\u6761\u4ef6\u8bed\u53e5\u6765\u6784\u5efa\u4e00\u4e2a\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u904d\u5386\u6570\u5b57\u5217\u8868\u5e76\u68c0\u67e5\u662f\u5426\u5b58\u5728\u8fde\u7eed\u7684\u5e8f\u5217\u3002\u901a\u8fc7\u7ef4\u62a4\u4e00\u4e2a\u4e34\u65f6\u5217\u8868\u6765\u5b58\u50a8\u5f53\u524d\u7684\u8fde\u7eed\u6570\u5b57\uff0c\u5f53\u9047\u5230\u4e0d\u8fde\u7eed\u7684\u6570\u5b57\u65f6\uff0c\u53ef\u4ee5\u5c06\u4e34\u65f6\u5217\u8868\u7684\u5185\u5bb9\u6dfb\u52a0\u5230\u6700\u7ec8\u7ed3\u679c\u5217\u8868\u4e2d\uff0c\u5e76\u91cd\u7f6e\u4e34\u65f6\u5217\u8868\u3002\u8fd9\u79cd\u65b9\u6cd5\u4f7f\u5f97\u60a8\u80fd\u591f\u63d0\u53d6\u6240\u6709\u7684\u8fde\u7eed\u6570\u5b57\u6bb5\u843d\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u5728Python\u4e2d\u7b5b\u9009\u8fde\u7eed\u6570\u5b57\uff0c\u53ef\u4ee5\u901a\u8fc7\u4f7f\u7528\u6b63\u5219\u8868\u8fbe\u5f0f\u3001\u5217\u8868\u89e3\u6790\u3001\u5faa\u73af\u904d\u5386\u7b49\u65b9\u6cd5\u5b9e\u73b0\u3002\u6b63\u5219\u8868\u8fbe\u5f0f\u63d0\u4f9b\u4e86\u4e00\u79cd\u5f3a\u5927\u800c [&hellip;]","protected":false},"author":3,"featured_media":960432,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[37],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/960428"}],"collection":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/comments?post=960428"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/960428\/revisions"}],"predecessor-version":[{"id":960437,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/960428\/revisions\/960437"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/960432"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=960428"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=960428"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=960428"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}