{"id":273923,"date":"2024-05-16T13:50:52","date_gmt":"2024-05-16T05:50:52","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/273923.html"},"modified":"2024-05-16T13:51:00","modified_gmt":"2024-05-16T05:51:00","slug":"%e6%9c%89%e4%bb%80%e4%b9%88%e9%a1%b9%e7%9b%ae%e5%8f%af%e4%bb%a5%e5%be%88%e5%a5%bd%e7%9a%84%e9%94%bb%e7%82%bc%e6%95%b0%e6%8d%ae%e7%bb%93%e6%9e%84%e4%b8%8e%e7%ae%97%e6%b3%95%e8%83%bd%e5%8a%9b%e5%90%97-2","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/273923.html","title":{"rendered":"\u6709\u4ec0\u4e48\u9879\u76ee\u53ef\u4ee5\u5f88\u597d\u7684\u953b\u70bc\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\u5417"},"content":{"rendered":"<p style=\"text-align:center\"><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/24195529\/11c96c96-11f8-4d54-9f1d-556f4e6d906a.webp\" alt=\"\u6709\u4ec0\u4e48\u9879\u76ee\u53ef\u4ee5\u5f88\u597d\u7684\u953b\u70bc\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\u5417\" \/><\/p>\n<p><p>\u6709\u591a\u4e2a\u9879\u76ee\u80fd\u591f\u953b\u70bc\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\uff0c\u5305\u62ec<strong>\u5b9e\u73b0\u4e00\u4e2a\u7b80\u5355\u7684\u641c\u7d22\u5f15\u64ce\u3001\u6784\u5efa\u4e00\u4e2a\u57fa\u4e8e\u56fe\u7684\u5bfc\u822a\u7cfb\u7edf\u3001\u5f00\u53d1\u4e00\u4e2a\u6587\u4ef6\u538b\u7f29\u7a0b\u5e8f\u3001\u521b\u5efa\u4e00\u4e2a\u4e8c\u53c9\u641c\u7d22\u6811\u7684\u56fe\u5f62\u754c\u9762\u3001\u4ee5\u53ca\u8bbe\u8ba1\u4e00\u6b3e\u89e3\u8c1c\u6e38\u620f<\/strong>\u3002\u5177\u4f53\u6765\u8bf4\uff0c\u5b9e\u73b0\u4e00\u4e2a\u7b80\u5355\u641c\u7d22\u5f15\u64ce\u80fd\u591f\u953b\u70bc\u5230\u4fe1\u606f\u68c0\u7d22\u3001\u6392\u5e8f\u7b97\u6cd5\u548c\u6811\u7ed3\u6784\u7b49\u591a\u65b9\u9762\u7684\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\uff0c\u56e0\u4e3a\u5b83\u9700\u8981\u9ad8\u6548\u5730\u7d22\u5f15\u548c\u68c0\u7d22\u6570\u636e\uff0c\u540c\u65f6\u8fd8\u8981\u7ba1\u7406\u548c\u4f18\u5316\u5927\u91cf\u7684\u6570\u636e\u7ed3\u6784\u548c\u7b97\u6cd5\u6d41\u7a0b\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001<strong>\u5b9e\u73b0\u4e00\u4e2a\u7b80\u5355\u7684\u641c\u7d22\u5f15\u64ce<\/strong><\/p>\n<\/p>\n<p><p>\u641c\u7d22\u5f15\u64ce\u7684\u5b9e\u73b0\u9700\u8981\u7528\u5230\u81ea\u7136\u8bed\u8a00\u5904\u7406\u3001\u4fe1\u606f\u68c0\u7d22\u6280\u672f\u548c\u6570\u636e\u7d22\u5f15\u7b56\u7565\uff0c\u975e\u5e38\u9002\u5408\u7ec3\u4e60\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u3002<\/p>\n<\/p>\n<ul>\n<li>\n<p>\u5168\u6587\u641c\u7d22\u7b97\u6cd5<\/p>\n<p>\u6784\u5efa\u641c\u7d22\u5f15\u64ce\u9996\u8981\u4efb\u52a1\u662f\u5b9e\u73b0\u5168\u6587\u641c\u7d22\u7b97\u6cd5\uff0c\u6bd4\u5982\u5012\u6392\u7d22\u5f15\u3002\u8fd9\u6d89\u53ca\u5230\u5bf9\u6587\u6863\u7684\u8bcd\u6c47\u8fdb\u884c\u7d22\u5f15\uff0c\u53ef\u4ee5\u901a\u8fc7\u54c8\u5e0c\u8868\u548c\u94fe\u8868\u7b49\u6570\u636e\u7ed3\u6784\u6765\u5b9e\u73b0\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p>\u4f18\u5316\u641c\u7d22\u7ed3\u679c<\/p>\n<p>\u5b9e\u73b0\u641c\u7d22\u7ed3\u679c\u7684\u6392\u5e8f\u548c\u4f18\u5316\u901a\u5e38\u7528\u5230\u5806\u6392\u5e8f\u6216\u5feb\u901f\u6392\u5e8f\u7b49\u7b97\u6cd5\uff0c\u4ee5\u53ca\u8003\u8651\u5982\u4f55\u8ba1\u7b97\u9875\u9762\u6743\u91cd\uff0c\u5982PageRank\u7b97\u6cd5\u7684\u5e94\u7528\u3002<\/p>\n<\/p>\n<\/li>\n<\/ul>\n<p><p>\u4e8c\u3001<strong>\u6784\u5efa\u4e00\u4e2a\u57fa\u4e8e\u56fe\u7684\u5bfc\u822a\u7cfb\u7edf<\/strong><\/p>\n<\/p>\n<p><p>\u56fe\u8bba\u662f\u5b66\u4e60\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u4e2d\u7684\u91cd\u8981\u73af\u8282\uff0c\u6784\u5efa\u56fe\u5f62\u5bfc\u822a\u7cfb\u7edf\u80fd\u6709\u6548\u953b\u70bc\u8fd9\u4e00\u80fd\u529b\u3002<\/p>\n<\/p>\n<ul>\n<li>\n<p>\u8def\u5f84\u67e5\u627e\u7b97\u6cd5<\/p>\n<p>\u5b9e\u73b0\u5730\u56fe\u4e0a\u70b9\u4e0e\u70b9\u4e4b\u95f4\u7684\u6700\u77ed\u8def\u5f84\u67e5\u627e\uff0c\u5e38\u89c1\u7b97\u6cd5\u6709Dijkstra\u7b97\u6cd5\u6216A*\u7b97\u6cd5\u7b49\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p>\u6027\u80fd\u4f18\u5316<\/p>\n<p>\u5982\u4f55\u5728\u5927\u89c4\u6a21\u5730\u56fe\u6570\u636e\u4e2d\u5b9e\u73b0\u5feb\u901f\u7684\u8def\u5f84\u67e5\u627e\uff0c\u6d89\u53ca\u6570\u636e\u7ed3\u6784\u7684\u4f18\u5316\uff0c\u5982\u4f7f\u7528\u7ea2\u9ed1\u6811\u7b49\u9ad8\u6548\u7684\u6570\u636e\u7ed3\u6784\u5b58\u50a8\u56fe\u8282\u70b9\u3002<\/p>\n<\/p>\n<\/li>\n<\/ul>\n<p><p>\u4e09\u3001<strong>\u5f00\u53d1\u4e00\u4e2a\u6587\u4ef6\u538b\u7f29\u7a0b\u5e8f<\/strong><\/p>\n<\/p>\n<p><p>\u6587\u4ef6\u538b\u7f29\u7a0b\u5e8f\u53ef\u4ee5\u7ec3\u4e60\u5bf9\u6811\u3001\u5806\u3001\u54c8\u5e0c\u8868\u7b49\u6570\u636e\u7ed3\u6784\u7684\u4f7f\u7528\u4ee5\u53ca\u5bf9\u8d2a\u5fc3\u7b97\u6cd5\u3001\u52a8\u6001\u89c4\u5212\u7684\u7406\u89e3\u3002<\/p>\n<\/p>\n<ul>\n<li>\n<p>Huffman\u7f16\u7801\u7b97\u6cd5<\/p>\n<p>Huffman\u6811\u662f\u5b9e\u73b0\u6587\u4ef6\u538b\u7f29\u7684\u7ecf\u5178\u7b97\u6cd5\uff0c\u53ef\u4ee5\u6709\u6548\u953b\u70bc\u5bf9\u4f18\u5148\u961f\u5217\uff08\u5806\uff09\u548c\u6811\u5f62\u6570\u636e\u7ed3\u6784\u7684\u638c\u63e1\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p>\u538b\u7f29\u6548\u7387\u5206\u6790<\/p>\n<p>\u5982\u4f55\u5e73\u8861\u538b\u7f29\u6bd4\u548c\u538b\u7f29\u901f\u5ea6\u7684\u5173\u7cfb\uff0c\u53ef\u80fd\u9700\u8981\u8fd0\u7528\u5230\u52a8\u6001\u89c4\u5212\u7b49\u7b97\u6cd5\u8fdb\u884c\u6570\u636e\u538b\u7f29\u7684\u7b56\u7565\u9009\u62e9\u3002<\/p>\n<\/p>\n<\/li>\n<\/ul>\n<p><p>\u56db\u3001<strong>\u521b\u5efa\u4e00\u4e2a\u4e8c\u53c9\u641c\u7d22\u6811\u7684\u56fe\u5f62\u754c\u9762<\/strong><\/p>\n<\/p>\n<p><p>\u901a\u8fc7\u53ef\u89c6\u5316\u7684\u65b9\u5f0f\u5c55\u793a\u6570\u636e\u7ed3\u6784\u7684\u52a8\u6001\u8fc7\u7a0b\uff0c\u6709\u52a9\u4e8e\u52a0\u6df1\u5bf9\u6570\u636e\u7ed3\u6784\u64cd\u4f5c\u7684\u7406\u89e3\u3002<\/p>\n<\/p>\n<ul>\n<li>\n<p>\u6811\u7ed3\u6784\u7684\u64cd\u4f5c\u5b9e\u8df5<\/p>\n<p>\u5305\u62ec\u4e86\u63d2\u5165\u3001\u5220\u9664\u3001\u67e5\u627e\u7b49\u64cd\u4f5c\uff0c\u901a\u8fc7\u56fe\u5f62\u754c\u9762\u6765\u52a8\u6001\u6f14\u793a\u4e8c\u53c9\u641c\u7d22\u6811\u7684\u53d8\u5316\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p>\u6811\u7ed3\u6784\u7684\u5e73\u8861\u8c03\u6574<\/p>\n<p>\u5982AVL\u6811\u6216\u7ea2\u9ed1\u6811\uff0c\u7ec3\u4e60\u6811\u7684\u81ea\u5e73\u8861\u64cd\u4f5c\u80fd\u591f\u52a0\u6df1\u5bf9\u5e73\u8861\u6811\u7684\u7406\u89e3\u3002<\/p>\n<\/p>\n<\/li>\n<\/ul>\n<p><p>\u4e94\u3001<strong>\u8bbe\u8ba1\u4e00\u6b3e\u89e3\u8c1c\u6e38\u620f<\/strong><\/p>\n<\/p>\n<p><p>\u89e3\u8c1c\u6e38\u620f\u5f80\u5f80\u9700\u8981\u7b97\u6cd5\u6765\u751f\u6210\u8c1c\u9898\u6216\u627e\u51fa\u89e3\u51b3\u65b9\u6848\uff0c\u9002\u5408\u7ec3\u4e60\u9012\u5f52\u548c\u641c\u7d22\u7b97\u6cd5\u3002<\/p>\n<\/p>\n<ul>\n<li>\n<p>\u8c1c\u9898\u751f\u6210\u7b97\u6cd5<\/p>\n<p>\u6bd4\u5982\u6570\u72ec\u6e38\u620f\uff0c\u9700\u8981\u7b97\u6cd5\u6765\u751f\u6210\u6ee1\u8db3\u89c4\u5219\u7684\u8c1c\u9898\uff0c\u8fd9\u53ef\u4ee5\u7ec3\u4e60\u7ec4\u5408\u7b97\u6cd5\u7684\u8fd0\u7528\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p>\u641c\u7d22\u89e3\u51b3\u65b9\u6848<\/p>\n<p>\u5bfb\u627e\u51fa\u6e38\u620f\u7684\u7b54\u6848\u53ef\u80fd\u9700\u8981\u7528\u5230\u6df1\u5ea6\u4f18\u5148\u641c\u7d22\u6216\u5e7f\u5ea6\u4f18\u5148\u641c\u7d22\u7b49\u7b97\u6cd5\u3002<\/p>\n<\/p>\n<\/li>\n<\/ul>\n<p><p>\u901a\u8fc7\u4e0a\u8ff0\u9879\u76ee\u7684\u5b9e\u8df5\uff0c\u4f60\u4e0d\u4ec5\u80fd\u7cfb\u7edf\u5730\u7ec3\u4e60\u4f7f\u7528\u5404\u79cd\u6570\u636e\u7ed3\u6784\u548c\u7b97\u6cd5\uff0c\u8fd8\u80fd\u63d0\u5347\u89e3\u51b3\u5b9e\u9645\u95ee\u9898\u7684\u80fd\u529b\u3002\u5728\u6bcf\u4e2a\u9879\u76ee\u4e2d\uff0c\u52a1\u5fc5\u6df1\u5165\u7406\u89e3\u5176\u4e2d\u6d89\u53ca\u5230\u7684\u6570\u636e\u7ed3\u6784\u548c\u7b97\u6cd5\u539f\u7406\uff0c\u5e76\u5728\u5b9e\u8df5\u4e2d\u4e0d\u65ad\u4f18\u5316\u548c\u6539\u8fdb\uff0c\u4ee5\u8fbe\u5230\u6700\u4f73\u7684\u5b66\u4e60\u6548\u679c\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p><strong>1. \u54ea\u4e9b\u5f00\u6e90\u9879\u76ee\u9002\u5408\u7528\u4e8e\u953b\u70bc\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\uff1f<\/strong><\/p>\n<p>\u5f88\u591a\u5f00\u6e90\u9879\u76ee\u90fd\u6d89\u53ca\u5230\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u7684\u5b9e\u73b0\uff0c\u9009\u62e9\u9002\u5408\u81ea\u5df1\u7684\u9879\u76ee\u662f\u4e00\u79cd\u5f88\u597d\u7684\u953b\u70bc\u65b9\u5f0f\u3002\u4e00\u4e9b\u8457\u540d\u7684\u5f00\u6e90\u9879\u76ee\u5982Linux\u5185\u6838\u3001Python\u89e3\u91ca\u5668\u3001LeetCode\u7b49\uff0c\u90fd\u662f\u5f88\u597d\u7684\u9009\u62e9\u3002\u53ef\u4ee5\u901a\u8fc7\u9605\u8bfb\u6e90\u4ee3\u7801\u3001\u8c03\u8bd5\u4ee5\u53ca\u63d0\u4ea4\u81ea\u5df1\u7684\u4ee3\u7801\u8d21\u732e\u6765\u63d0\u9ad8\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u7684\u80fd\u529b\u3002<\/p>\n<p><strong>2. \u5982\u4f55\u4f7f\u7528\u7ade\u8d5b\u6765\u63d0\u9ad8\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\uff1f<\/strong><\/p>\n<p>\u53c2\u52a0\u7f16\u7a0b\u7ade\u8d5b\u662f\u4e00\u4e2a\u975e\u5e38\u597d\u7684\u953b\u70bc\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\u7684\u9014\u5f84\u3002\u4f8b\u5982\uff0c\u56fd\u9645\u7a0b\u5e8f\u8bbe\u8ba1\u7ade\u8d5b\uff08ACM-ICPC\uff09\u3001Google Code Jam\u3001Facebook Hacker Cup\u7b49\u90fd\u662f\u5f88\u53d7\u6b22\u8fce\u7684\u7ade\u8d5b\u3002\u901a\u8fc7\u53c2\u52a0\u7ade\u8d5b\uff0c\u53ef\u4ee5\u63a5\u89e6\u5230\u5404\u79cd\u7c7b\u578b\u7684\u7f16\u7a0b\u9898\u76ee\uff0c\u953b\u70bc\u81ea\u5df1\u7684\u601d\u7ef4\u80fd\u529b\u548c\u7b97\u6cd5\u5b9e\u73b0\u80fd\u529b\u3002<\/p>\n<p><strong>3. \u5728\u65e5\u5e38\u5f00\u53d1\u4e2d\u5982\u4f55\u953b\u70bc\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\uff1f<\/strong><\/p>\n<p>\u65e5\u5e38\u5f00\u53d1\u4e2d\uff0c\u53ef\u4ee5\u901a\u8fc7\u89e3\u51b3\u4e00\u4e9b\u5e38\u89c1\u7684\u7b97\u6cd5\u95ee\u9898\u6765\u953b\u70bc\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\u3002\u6bd4\u5982\uff0c\u5b9e\u73b0\u4e00\u4e2a\u94fe\u8868\u3001\u6811\u7b49\u6570\u636e\u7ed3\u6784\uff0c\u6216\u8005\u89e3\u51b3\u4e00\u4e9b\u5e38\u89c1\u7684\u7b97\u6cd5\u95ee\u9898\uff0c\u5982\u67e5\u627e\u6700\u77ed\u8def\u5f84\u3001\u6392\u5e8f\u7b49\u3002\u53e6\u5916\uff0c\u5728\u7f16\u5199\u4ee3\u7801\u65f6\uff0c\u53ef\u4ee5\u5c1d\u8bd5\u4f7f\u7528\u4e0d\u540c\u7684\u6570\u636e\u7ed3\u6784\u548c\u7b97\u6cd5\u6765\u4f18\u5316\u6027\u80fd\uff0c\u4ece\u800c\u63d0\u9ad8\u81ea\u5df1\u7684\u80fd\u529b\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u6709\u591a\u4e2a\u9879\u76ee\u80fd\u591f\u953b\u70bc\u6570\u636e\u7ed3\u6784\u4e0e\u7b97\u6cd5\u80fd\u529b\uff0c\u5305\u62ec\u5b9e\u73b0\u4e00\u4e2a\u7b80\u5355\u7684\u641c\u7d22\u5f15\u64ce\u3001\u6784\u5efa\u4e00\u4e2a\u57fa\u4e8e\u56fe\u7684\u5bfc\u822a\u7cfb\u7edf\u3001\u5f00\u53d1\u4e00\u4e2a\u6587\u4ef6\u538b\u7f29\u7a0b [&hellip;]","protected":false},"author":3,"featured_media":273935,"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\/273923"}],"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=273923"}],"version-history":[{"count":0,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/273923\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/273935"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=273923"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=273923"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=273923"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}