{"id":1123488,"date":"2025-01-08T19:32:45","date_gmt":"2025-01-08T11:32:45","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1123488.html"},"modified":"2025-01-08T19:32:48","modified_gmt":"2025-01-08T11:32:48","slug":"python%e5%a6%82%e4%bd%95%e8%bf%9e%e6%8e%a5%e5%a4%9a%e4%b8%aa%e5%88%97%e8%a1%a8%e7%9a%84%e5%ad%97%e7%ac%a6%e4%b8%b2","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/1123488.html","title":{"rendered":"python\u5982\u4f55\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25084930\/52e42cd2-d759-41dd-8208-6d3f7f1815be.webp\" alt=\"python\u5982\u4f55\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32\" \/><\/p>\n<p><p> <strong>Python\u4e2d\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u51e0\u79cd\u65b9\u6cd5\u6765\u5b9e\u73b0\uff1a\u4f7f\u7528<code>+<\/code>\u64cd\u4f5c\u7b26\u3001\u4f7f\u7528<code>extend()<\/code>\u65b9\u6cd5\u3001\u4f7f\u7528\u5217\u8868\u89e3\u6790\u548c<code>join()<\/code>\u65b9\u6cd5\u3002\u5176\u4e2d\uff0c\u6700\u5e38\u7528\u4e14\u9ad8\u6548\u7684\u65b9\u6cd5\u662f\u4f7f\u7528<code>join()<\/code>\u65b9\u6cd5\u3002<\/strong> \u4e0b\u9762\u6211\u4eec\u5c06\u8be6\u7ec6\u8ba8\u8bba\u8fd9\u51e0\u79cd\u65b9\u6cd5\uff0c\u5e76\u5bf9\u5176\u4e2d\u6700\u5e38\u7528\u7684\u4e00\u79cd\u8fdb\u884c\u6df1\u5165\u89e3\u6790\u3002<\/p>\n<\/p>\n<p><h3>\u4e00\u3001\u4f7f\u7528<code>+<\/code>\u64cd\u4f5c\u7b26\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32<\/h3>\n<\/p>\n<p><p>\u4f7f\u7528<code>+<\/code>\u64cd\u4f5c\u7b26\u662fPython\u4e2d\u6700\u7b80\u5355\u76f4\u63a5\u7684\u65b9\u6cd5\uff0c\u5b83\u53ef\u4ee5\u5c06\u591a\u4e2a\u5217\u8868\u76f4\u63a5\u76f8\u52a0\uff0c\u751f\u6210\u4e00\u4e2a\u65b0\u7684\u5217\u8868\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">list1 = [&#39;Hello&#39;, &#39;world&#39;]<\/p>\n<p>list2 = [&#39;Python&#39;, &#39;is&#39;, &#39;great&#39;]<\/p>\n<p>list3 = [&#39;Let&#39;, &#39;us&#39;, &#39;learn&#39;]<\/p>\n<p>combined_list = list1 + list2 + list3<\/p>\n<p>print(combined_list)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p><strong>\u89e3\u91ca\uff1a<\/strong> \u4e0a\u8ff0\u4ee3\u7801\u4e2d\uff0c\u901a\u8fc7<code>+<\/code>\u64cd\u4f5c\u7b26\uff0c\u6211\u4eec\u5c06<code>list1<\/code>\u3001<code>list2<\/code>\u548c<code>list3<\/code>\u8fde\u63a5\u6210\u4e86\u4e00\u4e2a\u65b0\u7684\u5217\u8868<code>combined_list<\/code>\u3002\u8fd9\u79cd\u65b9\u6cd5\u76f4\u89c2\u3001\u6613\u7406\u89e3\uff0c\u4f46\u5728\u5904\u7406\u5927\u91cf\u6570\u636e\u65f6\u6548\u7387\u8f83\u4f4e\uff0c\u56e0\u4e3a\u6bcf\u6b21\u76f8\u52a0\u90fd\u4f1a\u521b\u5efa\u4e00\u4e2a\u65b0\u7684\u5217\u8868\u5bf9\u8c61\u3002<\/p>\n<\/p>\n<p><h3>\u4e8c\u3001\u4f7f\u7528<code>extend()<\/code>\u65b9\u6cd5\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32<\/h3>\n<\/p>\n<p><p><code>extend()<\/code>\u65b9\u6cd5\u53ef\u4ee5\u5728\u539f\u6709\u5217\u8868\u7684\u57fa\u7840\u4e0a\uff0c\u76f4\u63a5\u5c06\u5176\u4ed6\u5217\u8868\u4e2d\u7684\u5143\u7d20\u6dfb\u52a0\u8fdb\u53bb\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">list1 = [&#39;Hello&#39;, &#39;world&#39;]<\/p>\n<p>list2 = [&#39;Python&#39;, &#39;is&#39;, &#39;great&#39;]<\/p>\n<p>list3 = [&#39;Let&#39;, &#39;us&#39;, &#39;learn&#39;]<\/p>\n<p>list1.extend(list2)<\/p>\n<p>list1.extend(list3)<\/p>\n<p>print(list1)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p><strong>\u89e3\u91ca\uff1a<\/strong> \u901a\u8fc7<code>extend()<\/code>\u65b9\u6cd5\uff0c\u6211\u4eec\u5c06<code>list2<\/code>\u548c<code>list3<\/code>\u4e2d\u7684\u5143\u7d20\u6dfb\u52a0\u5230\u4e86<code>list1<\/code>\u4e2d\u3002\u6b64\u65b9\u6cd5\u4e0d\u4f1a\u521b\u5efa\u65b0\u7684\u5217\u8868\u5bf9\u8c61\uff0c\u800c\u662f\u4fee\u6539\u539f\u6709\u5217\u8868\uff0c\u6548\u7387\u76f8\u5bf9\u8f83\u9ad8\u3002<\/p>\n<\/p>\n<p><h3>\u4e09\u3001\u4f7f\u7528\u5217\u8868\u89e3\u6790\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32<\/h3>\n<\/p>\n<p><p>\u5217\u8868\u89e3\u6790\u662f\u4e00\u79cdPython\u7279\u6709\u7684\u7b80\u6d01\u4e14\u5f3a\u5927\u7684\u6784\u9020\u5217\u8868\u7684\u65b9\u6cd5\uff0c\u53ef\u4ee5\u7528\u4e8e\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">list1 = [&#39;Hello&#39;, &#39;world&#39;]<\/p>\n<p>list2 = [&#39;Python&#39;, &#39;is&#39;, &#39;great&#39;]<\/p>\n<p>list3 = [&#39;Let&#39;, &#39;us&#39;, &#39;learn&#39;]<\/p>\n<p>combined_list = [item for sublist in [list1, list2, list3] for item in sublist]<\/p>\n<p>print(combined_list)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p><strong>\u89e3\u91ca\uff1a<\/strong> \u5728\u4e0a\u8ff0\u4ee3\u7801\u4e2d\uff0c\u901a\u8fc7\u5d4c\u5957\u7684\u5217\u8868\u89e3\u6790\uff0c\u6211\u4eec\u5c06<code>list1<\/code>\u3001<code>list2<\/code>\u548c<code>list3<\/code>\u8fde\u63a5\u6210\u4e86\u4e00\u4e2a\u65b0\u7684\u5217\u8868<code>combined_list<\/code>\u3002\u8fd9\u79cd\u65b9\u6cd5\u7b80\u6d01\u4e14\u9ad8\u6548\uff0c\u5c24\u5176\u9002\u7528\u4e8e\u8f83\u590d\u6742\u7684\u5217\u8868\u8fde\u63a5\u64cd\u4f5c\u3002<\/p>\n<\/p>\n<p><h3>\u56db\u3001\u4f7f\u7528<code>join()<\/code>\u65b9\u6cd5\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32<\/h3>\n<\/p>\n<p><p><code>join()<\/code>\u65b9\u6cd5\u662f\u6700\u5e38\u7528\u4e14\u9ad8\u6548\u7684\u65b9\u6cd5\u4e4b\u4e00\uff0c\u7279\u522b\u9002\u7528\u4e8e\u5c06\u591a\u4e2a\u5b57\u7b26\u4e32\u8fde\u63a5\u6210\u4e00\u4e2a\u5b57\u7b26\u4e32\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">list1 = [&#39;Hello&#39;, &#39;world&#39;]<\/p>\n<p>list2 = [&#39;Python&#39;, &#39;is&#39;, &#39;great&#39;]<\/p>\n<p>list3 = [&#39;Let&#39;, &#39;us&#39;, &#39;learn&#39;]<\/p>\n<p>combined_list = list1 + list2 + list3<\/p>\n<p>result_string = &#39; &#39;.join(combined_list)<\/p>\n<p>print(result_string)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p><strong>\u8be6\u7ec6\u89e3\u6790\uff1a<\/strong> \u5728\u4e0a\u8ff0\u4ee3\u7801\u4e2d\uff0c\u6211\u4eec\u9996\u5148\u901a\u8fc7<code>+<\/code>\u64cd\u4f5c\u7b26\u5c06<code>list1<\/code>\u3001<code>list2<\/code>\u548c<code>list3<\/code>\u8fde\u63a5\u6210\u4e86\u4e00\u4e2a\u65b0\u7684\u5217\u8868<code>combined_list<\/code>\uff0c\u7136\u540e\u901a\u8fc7<code>join()<\/code>\u65b9\u6cd5\u5c06<code>combined_list<\/code>\u4e2d\u7684\u6240\u6709\u5b57\u7b26\u4e32\u8fde\u63a5\u6210\u4e86\u4e00\u4e2a\u5b57\u7b26\u4e32<code>result_string<\/code>\uff0c\u5e76\u4e14\u4f7f\u7528\u7a7a\u683c\u4f5c\u4e3a\u5206\u9694\u7b26\u3002<code>join()<\/code>\u65b9\u6cd5\u7684\u6548\u7387\u975e\u5e38\u9ad8\uff0c\u56e0\u4e3a\u5b83\u662f\u4e13\u95e8\u4e3a\u5b57\u7b26\u4e32\u8fde\u63a5\u8bbe\u8ba1\u7684\u3002<\/p>\n<\/p>\n<p><h3>\u4e94\u3001\u4e0d\u540c\u65b9\u6cd5\u7684\u6027\u80fd\u6bd4\u8f83<\/h3>\n<\/p>\n<p><p>\u5728\u5b9e\u9645\u5e94\u7528\u4e2d\uff0c\u9009\u62e9\u54ea\u79cd\u65b9\u6cd5\u53d6\u51b3\u4e8e\u5177\u4f53\u7684\u573a\u666f\u548c\u6570\u636e\u89c4\u6a21\u3002\u4e0b\u9762\u6211\u4eec\u901a\u8fc7\u4e00\u4e9b\u6027\u80fd\u6d4b\u8bd5\u6765\u6bd4\u8f83\u4e0d\u540c\u65b9\u6cd5\u7684\u6548\u7387\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import timeit<\/p>\n<p>list1 = [&#39;Hello&#39;, &#39;world&#39;]<\/p>\n<p>list2 = [&#39;Python&#39;, &#39;is&#39;, &#39;great&#39;]<\/p>\n<p>list3 = [&#39;Let&#39;, &#39;us&#39;, &#39;learn&#39;]<\/p>\n<h2><strong>\u4f7f\u7528 + \u64cd\u4f5c\u7b26<\/strong><\/h2>\n<p>def plus_operator():<\/p>\n<p>    combined_list = list1 + list2 + list3<\/p>\n<p>    return combined_list<\/p>\n<h2><strong>\u4f7f\u7528 extend() \u65b9\u6cd5<\/strong><\/h2>\n<p>def extend_method():<\/p>\n<p>    combined_list = list1[:]<\/p>\n<p>    combined_list.extend(list2)<\/p>\n<p>    combined_list.extend(list3)<\/p>\n<p>    return combined_list<\/p>\n<h2><strong>\u4f7f\u7528\u5217\u8868\u89e3\u6790<\/strong><\/h2>\n<p>def list_comprehension():<\/p>\n<p>    combined_list = [item for sublist in [list1, list2, list3] for item in sublist]<\/p>\n<p>    return combined_list<\/p>\n<h2><strong>\u4f7f\u7528 join() \u65b9\u6cd5<\/strong><\/h2>\n<p>def join_method():<\/p>\n<p>    combined_list = list1 + list2 + list3<\/p>\n<p>    result_string = &#39; &#39;.join(combined_list)<\/p>\n<p>    return result_string<\/p>\n<h2><strong>\u6d4b\u8bd5\u6bcf\u4e2a\u65b9\u6cd5\u7684\u6267\u884c\u65f6\u95f4<\/strong><\/h2>\n<p>print(&quot;Plus operator:&quot;, timeit.timeit(plus_operator, number=100000))<\/p>\n<p>print(&quot;Extend method:&quot;, timeit.timeit(extend_method, number=100000))<\/p>\n<p>print(&quot;List comprehension:&quot;, timeit.timeit(list_comprehension, number=100000))<\/p>\n<p>print(&quot;Join method:&quot;, timeit.timeit(join_method, number=100000))<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p><strong>\u89e3\u91ca\uff1a<\/strong> \u4e0a\u8ff0\u4ee3\u7801\u901a\u8fc7<code>timeit<\/code>\u6a21\u5757\u6d4b\u8bd5\u4e86\u6bcf\u79cd\u65b9\u6cd5\u7684\u6267\u884c\u65f6\u95f4\u3002\u7ed3\u679c\u663e\u793a\uff0c\u5bf9\u4e8e\u8f83\u5c0f\u7684\u5217\u8868\uff0c\u51e0\u79cd\u65b9\u6cd5\u7684\u6027\u80fd\u5dee\u5f02\u4e0d\u5927\uff1b\u4f46\u5bf9\u4e8e\u8f83\u5927\u7684\u5217\u8868\uff0c<code>extend()<\/code>\u65b9\u6cd5\u548c<code>join()<\/code>\u65b9\u6cd5\u7684\u6548\u7387\u66f4\u9ad8\u3002<\/p>\n<\/p>\n<p><h3>\u516d\u3001\u5e94\u7528\u573a\u666f\u5206\u6790<\/h3>\n<\/p>\n<ol>\n<li><strong>\u5c0f\u89c4\u6a21\u6570\u636e\u5904\u7406\uff1a<\/strong> \u5982\u679c\u5904\u7406\u7684\u6570\u636e\u91cf\u8f83\u5c0f\uff08\u5982\u51e0\u5341\u4e2a\u5b57\u7b26\u4e32\uff09\uff0c\u53ef\u4ee5\u4f7f\u7528<code>+<\/code>\u64cd\u4f5c\u7b26\u6216\u5217\u8868\u89e3\u6790\uff0c\u8fd9\u4e24\u79cd\u65b9\u6cd5\u76f4\u89c2\u4e14\u6613\u4e8e\u7406\u89e3\u3002<\/li>\n<li><strong>\u5927\u89c4\u6a21\u6570\u636e\u5904\u7406\uff1a<\/strong> \u5982\u679c\u5904\u7406\u7684\u6570\u636e\u91cf\u8f83\u5927\uff08\u5982\u6210\u5343\u4e0a\u4e07\u4e2a\u5b57\u7b26\u4e32\uff09\uff0c\u5efa\u8bae\u4f7f\u7528<code>extend()<\/code>\u65b9\u6cd5\u6216<code>join()<\/code>\u65b9\u6cd5\uff0c\u8fd9\u4e24\u79cd\u65b9\u6cd5\u6548\u7387\u66f4\u9ad8\uff0c\u5c24\u5176\u662f\u5728\u9700\u8981\u751f\u6210\u4e00\u4e2a\u6700\u7ec8\u5b57\u7b26\u4e32\u65f6\uff0c<code>join()<\/code>\u65b9\u6cd5\u662f\u6700\u4f73\u9009\u62e9\u3002<\/li>\n<li><strong>\u5b9e\u65f6\u6570\u636e\u5904\u7406\uff1a<\/strong> \u5728\u9700\u8981\u5b9e\u65f6\u5904\u7406\u6570\u636e\u7684\u573a\u666f\uff08\u5982\u6570\u636e\u6d41\u5904\u7406\uff09\uff0c\u5e94\u5c3d\u91cf\u907f\u514d\u4f7f\u7528<code>+<\/code>\u64cd\u4f5c\u7b26\uff0c\u56e0\u4e3a\u5176\u4f1a\u4e0d\u65ad\u521b\u5efa\u65b0\u7684\u5217\u8868\u5bf9\u8c61\uff0c\u5f71\u54cd\u6027\u80fd\u3002<\/li>\n<\/ol>\n<p><h3>\u4e03\u3001\u603b\u7ed3<\/h3>\n<\/p>\n<p><p>\u603b\u7684\u6765\u8bf4\uff0cPython\u63d0\u4f9b\u4e86\u591a\u79cd\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u5b57\u7b26\u4e32\u7684\u65b9\u6cd5\uff0c\u6bcf\u79cd\u65b9\u6cd5\u90fd\u6709\u5176\u9002\u7528\u7684\u573a\u666f\u3002<strong>\u5bf9\u4e8e\u9ad8\u6548\u7684\u5b57\u7b26\u4e32\u8fde\u63a5\uff0c<code>join()<\/code>\u65b9\u6cd5\u662f\u6700\u4f73\u9009\u62e9<\/strong>\u3002\u5728\u5b9e\u9645\u5e94\u7528\u4e2d\uff0c\u5e94\u6839\u636e\u5177\u4f53\u9700\u6c42\u9009\u62e9\u6700\u5408\u9002\u7684\u65b9\u6cd5\uff0c\u4ee5\u8fbe\u5230\u6700\u4f73\u7684\u6027\u80fd\u548c\u4ee3\u7801\u53ef\u8bfb\u6027\u3002<\/p>\n<\/p>\n<p><p>\u5e0c\u671b\u901a\u8fc7\u4e0a\u8ff0\u8be6\u7ec6\u89e3\u6790\u548c\u793a\u4f8b\u4ee3\u7801\uff0c\u80fd\u5e2e\u52a9\u4f60\u66f4\u597d\u5730\u7406\u89e3\u548c\u638c\u63e1Python\u4e2d\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u5b57\u7b26\u4e32\u7684\u65b9\u6cd5\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u5728Python\u4e2d\u5c06\u591a\u4e2a\u5217\u8868\u4e2d\u7684\u5b57\u7b26\u4e32\u5408\u5e76\u4e3a\u4e00\u4e2a\u5b57\u7b26\u4e32\uff1f<\/strong><br \/>\u5728Python\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528<code>join()<\/code>\u65b9\u6cd5\u5c06\u591a\u4e2a\u5217\u8868\u4e2d\u7684\u5b57\u7b26\u4e32\u8fde\u63a5\u6210\u4e00\u4e2a\u5355\u4e00\u7684\u5b57\u7b26\u4e32\u3002\u5177\u4f53\u64cd\u4f5c\u662f\uff0c\u9996\u5148\u9700\u8981\u5c06\u5217\u8868\u4e2d\u7684\u6240\u6709\u5b57\u7b26\u4e32\u5143\u7d20\u63d0\u53d6\u51fa\u6765\uff0c\u7136\u540e\u4f7f\u7528<code>join()<\/code>\u65b9\u6cd5\u6307\u5b9a\u8fde\u63a5\u7b26\uff0c\u4f8b\u5982\u7a7a\u683c\u3001\u9017\u53f7\u6216\u5176\u4ed6\u5b57\u7b26\u3002\u793a\u4f8b\u4ee3\u7801\u5982\u4e0b\uff1a<\/p>\n<pre><code class=\"language-python\">list1 = [&#39;Hello&#39;, &#39;World&#39;]\nlist2 = [&#39;Python&#39;, &#39;is&#39;, &#39;great&#39;]\ncombined_list = list1 + list2\nresult = &#39; &#39;.join(combined_list)\nprint(result)  # \u8f93\u51fa: Hello World Python is great\n<\/code><\/pre>\n<p><strong>\u5728\u8fde\u63a5\u5217\u8868\u5b57\u7b26\u4e32\u65f6\uff0c\u5982\u4f55\u907f\u514d\u7a7a\u683c\u6216\u5176\u4ed6\u5206\u9694\u7b26\uff1f<\/strong><br \/>\u4f7f\u7528<code>join()<\/code>\u65b9\u6cd5\u65f6\uff0c\u53ef\u4ee5\u9009\u62e9\u4e0d\u540c\u7684\u5206\u9694\u7b26\u3002\u5982\u679c\u5e0c\u671b\u5728\u8fde\u63a5\u5b57\u7b26\u4e32\u65f6\u4e0d\u6dfb\u52a0\u4efb\u4f55\u5206\u9694\u7b26\uff0c\u53ea\u9700\u4f7f\u7528\u7a7a\u5b57\u7b26\u4e32\u4f5c\u4e3a\u8fde\u63a5\u7b26\u3002\u4f8b\u5982\uff1a<\/p>\n<pre><code class=\"language-python\">list1 = [&#39;Hello&#39;, &#39;World&#39;]\nresult = &#39;&#39;.join(list1)\nprint(result)  # \u8f93\u51fa: HelloWorld\n<\/code><\/pre>\n<p><strong>\u662f\u5426\u53ef\u4ee5\u4f7f\u7528\u5217\u8868\u63a8\u5bfc\u5f0f\u6765\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32\uff1f<\/strong><br \/>\u786e\u5b9e\u53ef\u4ee5\u3002\u5229\u7528\u5217\u8868\u63a8\u5bfc\u5f0f\u53ef\u4ee5\u8f7b\u677e\u5730\u5904\u7406\u591a\u4e2a\u5217\u8868\u5e76\u8fde\u63a5\u5b57\u7b26\u4e32\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u65b9\u5f0f\u5c06\u591a\u4e2a\u5217\u8868\u4e2d\u7684\u5b57\u7b26\u4e32\u5408\u5e76\uff1a<\/p>\n<pre><code class=\"language-python\">list1 = [&#39;Hello&#39;, &#39;World&#39;]\nlist2 = [&#39;Python&#39;, &#39;is&#39;, &#39;great&#39;]\ncombined_result = &#39; &#39;.join([item for sublist in [list1, list2] for item in sublist])\nprint(combined_result)  # \u8f93\u51fa: Hello World Python is great\n<\/code><\/pre>\n<p>\u8fd9\u79cd\u65b9\u6cd5\u4f7f\u5f97\u4ee3\u7801\u66f4\u52a0\u7b80\u6d01\uff0c\u540c\u65f6\u4e5f\u63d0\u9ad8\u4e86\u53ef\u8bfb\u6027\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"Python\u4e2d\u8fde\u63a5\u591a\u4e2a\u5217\u8868\u7684\u5b57\u7b26\u4e32\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u51e0\u79cd\u65b9\u6cd5\u6765\u5b9e\u73b0\uff1a\u4f7f\u7528+\u64cd\u4f5c\u7b26\u3001\u4f7f\u7528extend()\u65b9\u6cd5\u3001\u4f7f\u7528\u5217\u8868 [&hellip;]","protected":false},"author":3,"featured_media":1123497,"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\/1123488"}],"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=1123488"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1123488\/revisions"}],"predecessor-version":[{"id":1123499,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1123488\/revisions\/1123499"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1123497"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1123488"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1123488"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1123488"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}