{"id":1120417,"date":"2025-01-08T18:56:17","date_gmt":"2025-01-08T10:56:17","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1120417.html"},"modified":"2025-01-08T18:56:19","modified_gmt":"2025-01-08T10:56:19","slug":"python%e7%9a%84for%e5%a6%82%e4%bd%95%e8%8e%b7%e5%be%97%e5%bd%93%e5%89%8d%e5%be%aa%e7%8e%af%e6%ac%a1%e6%95%b0","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1120417.html","title":{"rendered":"python\u7684for\u5982\u4f55\u83b7\u5f97\u5f53\u524d\u5faa\u73af\u6b21\u6570"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25083104\/92b6dffd-d2b1-4db4-b1f3-0f71b9d57bee.webp\" alt=\"python\u7684for\u5982\u4f55\u83b7\u5f97\u5f53\u524d\u5faa\u73af\u6b21\u6570\" \/><\/p>\n<p><p> <strong>\u5728Python\u4e2d\uff0c\u53ef\u4ee5\u901a\u8fc7\u4f7f\u7528<code>enumerate()<\/code>\u51fd\u6570\u6765\u83b7\u53d6\u5f53\u524d\u5faa\u73af\u6b21\u6570\u3001\u4f7f\u7528\u81ea\u5b9a\u4e49\u8ba1\u6570\u5668\u53d8\u91cf\u3001\u4ee5\u53ca\u5229\u7528\u5217\u8868\u7406\u89e3\u548c\u751f\u6210\u5668\u8868\u8fbe\u5f0f\u7b49\u65b9\u5f0f\u6765\u83b7\u5f97\u5f53\u524d\u5faa\u73af\u6b21\u6570\u3002<\/strong> \u5176\u4e2d\uff0c<strong><code>enumerate()<\/code>\u51fd\u6570\u662f\u6700\u5e38\u7528\u4e14\u6700\u7b80\u6d01\u7684\u65b9\u6cd5<\/strong>\uff0c\u56e0\u4e3a\u5b83\u4e0d\u4ec5\u63d0\u4f9b\u5f53\u524d\u5143\u7d20\uff0c\u8fd8\u63d0\u4f9b\u5f53\u524d\u5143\u7d20\u7684\u7d22\u5f15\u3002\u63a5\u4e0b\u6765\uff0c\u6211\u4eec\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u8fd9\u51e0\u79cd\u65b9\u6cd5\u53ca\u5176\u5e94\u7528\u573a\u666f\u3002<\/p>\n<\/p>\n<p><h3>\u4e00\u3001\u4f7f\u7528<code>enumerate()<\/code>\u51fd\u6570<\/h3>\n<\/p>\n<p><p><code>enumerate()<\/code> \u662fPython\u5185\u7f6e\u51fd\u6570\uff0c\u5b83\u8fd4\u56de\u4e00\u4e2a\u679a\u4e3e\u5bf9\u8c61\u3002\u8fd9\u4e2a\u679a\u4e3e\u5bf9\u8c61\u662f\u4e00\u4e2a\u5305\u542b\u6bcf\u4e2a\u5143\u7d20\u7d22\u5f15\u548c\u5143\u7d20\u672c\u8eab\u7684\u5143\u7ec4\u3002\u5b83\u5e38\u7528\u4e8e\u9700\u8981\u5728\u5faa\u73af\u4e2d\u8ddf\u8e2a\u7d22\u5f15\u7684\u573a\u666f\u3002<\/p>\n<\/p>\n<p><h4>1\u3001\u57fa\u672c\u7528\u6cd5<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">fruits = [&#39;apple&#39;, &#39;banana&#39;, &#39;cherry&#39;]<\/p>\n<p>for index, fruit in enumerate(fruits):<\/p>\n<p>    print(f&quot;Index: {index}, Fruit: {fruit}&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u4e0a\u8ff0\u4ee3\u7801\u4e2d\uff0c<code>enumerate(fruits)<\/code>\u8fd4\u56de\u4e00\u4e2a\u679a\u4e3e\u5bf9\u8c61\uff0c<code>index<\/code>\u662f\u5f53\u524d\u5faa\u73af\u6b21\u6570\uff0c\u800c<code>fruit<\/code>\u662f\u5f53\u524d\u5143\u7d20\u3002<\/p>\n<\/p>\n<p><h4>2\u3001\u6307\u5b9a\u8d77\u59cb\u7d22\u5f15<\/h4>\n<\/p>\n<p><p><code>enumerate()<\/code>\u51fd\u6570\u8fd8\u5141\u8bb8\u4f60\u6307\u5b9a\u8d77\u59cb\u7d22\u5f15\uff0c\u9ed8\u8ba4\u662f\u4ece0\u5f00\u59cb\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">for index, fruit in enumerate(fruits, start=1):<\/p>\n<p>    print(f&quot;Index: {index}, Fruit: {fruit}&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4e0a\u9762\u7684\u4ee3\u7801\u4e2d\uff0c\u5faa\u73af\u6b21\u6570\u4ece1\u5f00\u59cb\uff0c\u800c\u4e0d\u662f\u9ed8\u8ba4\u76840\u3002<\/p>\n<\/p>\n<p><h3>\u4e8c\u3001\u81ea\u5b9a\u4e49\u8ba1\u6570\u5668\u53d8\u91cf<\/h3>\n<\/p>\n<p><p>\u5728\u67d0\u4e9b\u60c5\u51b5\u4e0b\uff0c\u4f60\u53ef\u80fd\u4e0d\u60f3\u4f7f\u7528<code>enumerate()<\/code>\u51fd\u6570\uff0c\u6b64\u65f6\u53ef\u4ee5\u624b\u52a8\u521b\u5efa\u4e00\u4e2a\u8ba1\u6570\u5668\u53d8\u91cf\u6765\u8ddf\u8e2a\u5faa\u73af\u6b21\u6570\u3002<\/p>\n<\/p>\n<p><h4>1\u3001\u57fa\u672c\u7528\u6cd5<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">fruits = [&#39;apple&#39;, &#39;banana&#39;, &#39;cherry&#39;]<\/p>\n<p>index = 0<\/p>\n<p>for fruit in fruits:<\/p>\n<p>    print(f&quot;Index: {index}, Fruit: {fruit}&quot;)<\/p>\n<p>    index += 1<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u4e2a\u4f8b\u5b50\u4e2d\uff0c\u6211\u4eec\u624b\u52a8\u7ef4\u62a4\u4e00\u4e2a\u8ba1\u6570\u5668\u53d8\u91cf<code>index<\/code>\uff0c\u5e76\u5728\u6bcf\u6b21\u5faa\u73af\u4e2d\u9012\u589e\u5b83\u3002<\/p>\n<\/p>\n<p><h4>2\u3001\u4f7f\u7528<code>itertools.count()<\/code><\/h4>\n<\/p>\n<p><p><code>itertools<\/code>\u6a21\u5757\u63d0\u4f9b\u4e86\u4e00\u4e2a\u66f4\u4f18\u96c5\u7684\u89e3\u51b3\u65b9\u6848\uff0c\u5373\u4f7f\u7528<code>count()<\/code>\u51fd\u6570\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import itertools<\/p>\n<p>counter = itertools.count()<\/p>\n<p>for fruit in fruits:<\/p>\n<p>    index = next(counter)<\/p>\n<p>    print(f&quot;Index: {index}, Fruit: {fruit}&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p><code>itertools.count()<\/code>\u8fd4\u56de\u4e00\u4e2a\u751f\u6210\u5668\uff0c\u6bcf\u6b21\u8c03\u7528<code>next()<\/code>\u90fd\u4f1a\u8fd4\u56de\u4e00\u4e2a\u9012\u589e\u7684\u6574\u6570\u3002<\/p>\n<\/p>\n<p><h3>\u4e09\u3001\u5217\u8868\u7406\u89e3\u548c\u751f\u6210\u5668\u8868\u8fbe\u5f0f<\/h3>\n<\/p>\n<p><p>\u5728\u67d0\u4e9b\u60c5\u51b5\u4e0b\uff0c\u5217\u8868\u7406\u89e3\u548c\u751f\u6210\u5668\u8868\u8fbe\u5f0f\u4e5f\u53ef\u4ee5\u7528\u4e8e\u8ddf\u8e2a\u5faa\u73af\u6b21\u6570\u3002<\/p>\n<\/p>\n<p><h4>1\u3001\u5217\u8868\u7406\u89e3<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">fruits = [&#39;apple&#39;, &#39;banana&#39;, &#39;cherry&#39;]<\/p>\n<p>indices = [i for i, fruit in enumerate(fruits)]<\/p>\n<p>print(indices)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd9\u4e2a\u4f8b\u5b50\u4e2d\uff0c\u6211\u4eec\u751f\u6210\u4e86\u4e00\u4e2a\u5305\u542b\u6240\u6709\u7d22\u5f15\u7684\u5217\u8868\u3002<\/p>\n<\/p>\n<p><h4>2\u3001\u751f\u6210\u5668\u8868\u8fbe\u5f0f<\/h4>\n<\/p>\n<p><pre><code class=\"language-python\">indices_gen = (i for i, fruit in enumerate(fruits))<\/p>\n<p>for index in indices_gen:<\/p>\n<p>    print(index)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u751f\u6210\u5668\u8868\u8fbe\u5f0f\u7684\u4f18\u70b9\u5728\u4e8e\u5b83\u662f\u60f0\u6027\u6c42\u503c\u7684\uff0c\u5373\u5728\u9700\u8981\u65f6\u624d\u4f1a\u751f\u6210\u5143\u7d20\uff0c\u8fd9\u5bf9\u4e8e\u5904\u7406\u5927\u6570\u636e\u96c6\u975e\u5e38\u6709\u7528\u3002<\/p>\n<\/p>\n<p><h3>\u56db\u3001\u5728\u5b9e\u9645\u5e94\u7528\u4e2d\u7684\u7efc\u5408\u8fd0\u7528<\/h3>\n<\/p>\n<p><h4>1\u3001\u5904\u7406\u6587\u4ef6\u884c\u6570<\/h4>\n<\/p>\n<p><p>\u5728\u5904\u7406\u6587\u4ef6\u65f6\uff0c\u5e38\u9700\u8981\u8ddf\u8e2a\u5f53\u524d\u884c\u6570\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">with open(&#39;example.txt&#39;) as file:<\/p>\n<p>    for lineno, line in enumerate(file, start=1):<\/p>\n<p>        print(f&quot;Line {lineno}: {line.strip()}&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u91cc\uff0c<code>enumerate()<\/code>\u51fd\u6570\u975e\u5e38\u65b9\u4fbf\u5730\u63d0\u4f9b\u4e86\u5f53\u524d\u884c\u53f7\u3002<\/p>\n<\/p>\n<p><h4>2\u3001\u6570\u636e\u5904\u7406\u548c\u5206\u6790<\/h4>\n<\/p>\n<p><p>\u5728\u6570\u636e\u5904\u7406\u548c\u5206\u6790\u4e2d\uff0c\u8ddf\u8e2a\u5faa\u73af\u6b21\u6570\u53ef\u4ee5\u5e2e\u52a9\u6211\u4eec\u8c03\u8bd5\u548c\u76d1\u63a7\u6570\u636e\u5904\u7406\u7684\u8fdb\u5c55\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">data = [10, 20, 30, 40, 50]<\/p>\n<p>results = []<\/p>\n<p>for index, value in enumerate(data):<\/p>\n<p>    result = value * 2  # \u5047\u8bbe\u6211\u4eec\u8fdb\u884c\u67d0\u79cd\u5904\u7406<\/p>\n<p>    results.append((index, result))<\/p>\n<p>print(results)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u4e2a\u4f8b\u5b50\u4e2d\uff0c\u6211\u4eec\u4e0d\u4ec5\u8ddf\u8e2a\u4e86\u6570\u636e\u5904\u7406\u7684\u7ed3\u679c\uff0c\u8fd8\u8bb0\u5f55\u4e86\u6bcf\u4e2a\u5904\u7406\u6b65\u9aa4\u7684\u7d22\u5f15\u3002<\/p>\n<\/p>\n<p><h3>\u4e94\u3001\u6027\u80fd\u6bd4\u8f83\u4e0e\u6ce8\u610f\u4e8b\u9879<\/h3>\n<\/p>\n<p><h4>1\u3001\u6027\u80fd\u6bd4\u8f83<\/h4>\n<\/p>\n<p><p>\u5728\u6027\u80fd\u65b9\u9762\uff0c<code>enumerate()<\/code>\u51fd\u6570\u548c\u624b\u52a8\u7ef4\u62a4\u8ba1\u6570\u5668\u53d8\u91cf\u7684\u6027\u80fd\u5dee\u5f02\u901a\u5e38\u53ef\u4ee5\u5ffd\u7565\u4e0d\u8ba1\u3002\u4ee5\u4e0b\u662f\u4e00\u4e2a\u7b80\u5355\u7684\u6027\u80fd\u6bd4\u8f83\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">import time<\/p>\n<p>fruits = [&#39;apple&#39;, &#39;banana&#39;, &#39;cherry&#39;] * 1000000<\/p>\n<h2><strong>\u4f7f\u7528 enumerate()<\/strong><\/h2>\n<p>start_time = time.time()<\/p>\n<p>for index, fruit in enumerate(fruits):<\/p>\n<p>    pass<\/p>\n<p>print(f&quot;Enumerate: {time.time() - start_time} seconds&quot;)<\/p>\n<h2><strong>\u4f7f\u7528\u624b\u52a8\u8ba1\u6570\u5668<\/strong><\/h2>\n<p>start_time = time.time()<\/p>\n<p>index = 0<\/p>\n<p>for fruit in fruits:<\/p>\n<p>    index += 1<\/p>\n<p>print(f&quot;Manual counter: {time.time() - start_time} seconds&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u4e2a\u793a\u4f8b\u4e2d\uff0c<code>enumerate()<\/code>\u548c\u624b\u52a8\u8ba1\u6570\u5668\u7684\u6027\u80fd\u975e\u5e38\u63a5\u8fd1\u3002<\/p>\n<\/p>\n<p><h4>2\u3001\u6ce8\u610f\u4e8b\u9879<\/h4>\n<\/p>\n<p><p>\u5728\u4f7f\u7528<code>enumerate()<\/code>\u51fd\u6570\u65f6\u9700\u8981\u6ce8\u610f\u4ee5\u4e0b\u51e0\u70b9\uff1a<\/p>\n<\/p>\n<ul>\n<li><strong>\u8d77\u59cb\u7d22\u5f15<\/strong>\uff1a\u786e\u4fdd\u4f60\u660e\u786e\u6307\u5b9a\u4e86\u8d77\u59cb\u7d22\u5f15\uff0c\u7279\u522b\u662f\u5728\u9700\u8981\u4ece\u975e\u96f6\u7d22\u5f15\u5f00\u59cb\u65f6\u3002<\/li>\n<li><strong>\u6027\u80fd<\/strong>\uff1a\u5bf9\u4e8e\u975e\u5e38\u5927\u7684\u6570\u636e\u96c6\uff0c\u751f\u6210\u5668\u8868\u8fbe\u5f0f\u53ef\u80fd\u66f4\u9002\u5408\uff0c\u56e0\u4e3a\u5b83\u4eec\u662f\u60f0\u6027\u6c42\u503c\u7684\u3002<\/li>\n<\/ul>\n<p><h3>\u516d\u3001\u603b\u7ed3<\/h3>\n<\/p>\n<p><p>\u901a\u8fc7\u4e0a\u8ff0\u65b9\u6cd5\uff0c\u4f60\u53ef\u4ee5\u5728Python\u4e2d\u65b9\u4fbf\u5730\u83b7\u5f97\u5f53\u524d\u5faa\u73af\u6b21\u6570\u3002<strong>\u4f7f\u7528<code>enumerate()<\/code>\u51fd\u6570\u662f\u6700\u5e38\u7528\u4e14\u7b80\u6d01\u7684\u65b9\u6cd5<\/strong>\uff0c\u4f46\u5728\u67d0\u4e9b\u7279\u5b9a\u573a\u666f\u4e2d\uff0c\u81ea\u5b9a\u4e49\u8ba1\u6570\u5668\u53d8\u91cf\u6216\u751f\u6210\u5668\u8868\u8fbe\u5f0f\u53ef\u80fd\u66f4\u52a0\u9002\u5408\u3002\u65e0\u8bba\u9009\u62e9\u54ea\u79cd\u65b9\u6cd5\uff0c\u7406\u89e3\u5176\u539f\u7406\u548c\u9002\u7528\u573a\u666f\u5c06\u5e2e\u52a9\u4f60\u7f16\u5199\u66f4\u9ad8\u6548\u3001\u66f4\u7b80\u6d01\u7684\u4ee3\u7801\u3002<\/p>\n<\/p>\n<p><p>\u5e0c\u671b\u8fd9\u7bc7\u6587\u7ae0\u80fd\u5e2e\u52a9\u4f60\u66f4\u597d\u5730\u7406\u89e3\u5982\u4f55\u5728Python\u4e2d\u83b7\u5f97\u5f53\u524d\u5faa\u73af\u6b21\u6570\uff0c\u5e76\u5e94\u7528\u5230\u5b9e\u9645\u7684\u7f16\u7a0b\u4e2d\u53bb\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u5728Python\u7684for\u5faa\u73af\u4e2d\u83b7\u53d6\u5f53\u524d\u7d22\u5f15\u503c\uff1f<\/strong><br \/>\u5728Python\u7684for\u5faa\u73af\u4e2d\uff0c\u53ef\u4ee5\u4f7f\u7528<code>enumerate()<\/code>\u51fd\u6570\u6765\u540c\u65f6\u83b7\u53d6\u5143\u7d20\u7684\u7d22\u5f15\u548c\u5bf9\u5e94\u7684\u503c\u3002\u793a\u4f8b\u5982\u4e0b\uff1a<\/p>\n<pre><code class=\"language-python\">items = [&#39;apple&#39;, &#39;banana&#39;, &#39;cherry&#39;]\nfor index, item in enumerate(items):\n    print(f&#39;Index: {index}, Item: {item}&#39;)\n<\/code><\/pre>\n<p>\u8fd9\u79cd\u65b9\u6cd5\u4f7f\u5f97\u60a8\u80fd\u591f\u5f88\u65b9\u4fbf\u5730\u83b7\u53d6\u5f53\u524d\u5faa\u73af\u7684\u6b21\u6570\u548c\u5f53\u524d\u5143\u7d20\u3002<\/p>\n<p><strong>\u662f\u5426\u53ef\u4ee5\u901a\u8fc7\u5176\u4ed6\u65b9\u6cd5\u83b7\u53d6\u5faa\u73af\u6b21\u6570\uff1f<\/strong><br \/>\u9664\u4e86\u4f7f\u7528<code>enumerate()<\/code>\uff0c\u8fd8\u53ef\u4ee5\u901a\u8fc7\u4f7f\u7528\u4e00\u4e2a\u989d\u5916\u7684\u8ba1\u6570\u5668\u53d8\u91cf\u6765\u624b\u52a8\u8ddf\u8e2a\u5faa\u73af\u6b21\u6570\u3002\u4ee5\u4e0b\u662f\u4e00\u4e2a\u793a\u4f8b\uff1a<\/p>\n<pre><code class=\"language-python\">items = [&#39;apple&#39;, &#39;banana&#39;, &#39;cherry&#39;]\ncounter = 0\nfor item in items:\n    print(f&#39;Count: {counter}, Item: {item}&#39;)\n    counter += 1\n<\/code><\/pre>\n<p>\u8fd9\u79cd\u65b9\u6cd5\u867d\u7136\u6709\u6548\uff0c\u4f46\u901a\u5e38\u4e0d\u5982<code>enumerate()<\/code>\u7b80\u6d01\u3002<\/p>\n<p><strong>\u5728Python\u7684for\u5faa\u73af\u4e2d\uff0c\u5faa\u73af\u6b21\u6570\u53ef\u4ee5\u5e94\u7528\u4e8e\u54ea\u4e9b\u573a\u666f\uff1f<\/strong><br \/>\u83b7\u53d6\u5faa\u73af\u6b21\u6570\u5728\u5f88\u591a\u573a\u666f\u4e2d\u90fd\u5f88\u6709\u7528\uff0c\u4f8b\u5982\u5728\u5904\u7406\u6570\u636e\u65f6\u9700\u8981\u8bb0\u5f55\u6bcf\u4e2a\u5143\u7d20\u7684\u7d22\u5f15\uff0c\u6216\u8005\u5728\u6761\u4ef6\u5224\u65ad\u4e2d\u6839\u636e\u5f53\u524d\u5faa\u73af\u6b21\u6570\u6267\u884c\u4e0d\u540c\u7684\u903b\u8f91\u3002\u8fd9\u5728\u6570\u636e\u5206\u6790\u3001<a href=\"https:\/\/docs.pingcode.com\/ask\/59192.html\" target=\"_blank\">\u673a\u5668\u5b66\u4e60<\/a>\u9884\u5904\u7406\u548c\u56fe\u50cf\u5904\u7406\u7b49\u9886\u57df\u7279\u522b\u5e38\u89c1\u3002\u901a\u8fc7\u7d22\u5f15\uff0c\u60a8\u53ef\u4ee5\u66f4\u597d\u5730\u63a7\u5236\u548c\u7ba1\u7406\u6570\u636e\u7684\u5904\u7406\u6d41\u7a0b\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u5728Python\u4e2d\uff0c\u53ef\u4ee5\u901a\u8fc7\u4f7f\u7528enumerate()\u51fd\u6570\u6765\u83b7\u53d6\u5f53\u524d\u5faa\u73af\u6b21\u6570\u3001\u4f7f\u7528\u81ea\u5b9a\u4e49\u8ba1\u6570\u5668\u53d8\u91cf\u3001\u4ee5\u53ca\u5229\u7528\u5217\u8868 [&hellip;]","protected":false},"author":3,"featured_media":1120424,"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\/1120417"}],"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=1120417"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1120417\/revisions"}],"predecessor-version":[{"id":1120425,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1120417\/revisions\/1120425"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1120424"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1120417"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1120417"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1120417"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}