{"id":923093,"date":"2024-12-26T14:43:52","date_gmt":"2024-12-26T06:43:52","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/923093.html"},"modified":"2024-12-26T14:43:54","modified_gmt":"2024-12-26T06:43:54","slug":"%e5%a6%82%e4%bd%95%e8%a3%85python","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/923093.html","title":{"rendered":"\u5982\u4f55\u88c5python"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/24211314\/975976f6-9d8a-43df-bdc4-73a63381bb26.webp\" alt=\"\u5982\u4f55\u88c5python\" \/><\/p>\n<p><p> <strong>\u88c5Python\u7684\u65b9\u6cd5\u5305\u62ec\uff1a\u4f7f\u7528Python\u5b98\u7f51\u4e0b\u8f7d\u5b89\u88c5\u5305\u3001\u4f7f\u7528\u5305\u7ba1\u7406\u5668\uff08\u5982Homebrew\u6216Chocolatey\uff09\u3001\u4f7f\u7528Anaconda\u3002\u63a8\u8350\u901a\u8fc7Python\u5b98\u7f51\u4e0b\u8f7d\u5b89\u88c5\u5305\uff0c\u56e0\u4e3a\u8fd9\u79cd\u65b9\u6cd5\u7b80\u5355\u76f4\u89c2\uff0c\u9002\u5408\u5927\u591a\u6570\u7528\u6237\u3002<\/strong>\u4e0b\u9762\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u901a\u8fc7Python\u5b98\u7f51\u4e0b\u8f7d\u5b89\u88c5\u5305\u7684\u65b9\u6cd5\u3002<\/p>\n<\/p>\n<p><p>\u4e0b\u8f7dPython\u5b89\u88c5\u5305\u7684\u6b65\u9aa4\uff1a<\/p>\n<\/p>\n<ol>\n<li><strong>\u8bbf\u95eePython\u5b98\u7f51<\/strong>\uff1a\u524d\u5f80<a href=\"https:\/\/www.python.org\/\">Python\u7684\u5b98\u65b9\u7f51\u7ad9<\/a>\uff0c\u5728\u9996\u9875\u7684\u4e0b\u8f7d\u533a\u57df\uff0c\u4f60\u4f1a\u770b\u5230\u5f53\u524d\u63a8\u8350\u7684Python\u7248\u672c\u3002<\/li>\n<li><strong>\u9009\u62e9\u5408\u9002\u7684\u7248\u672c<\/strong>\uff1a\u6839\u636e\u4f60\u7684\u64cd\u4f5c\u7cfb\u7edf\uff08Windows\u3001macOS\u3001Linux\uff09\u9009\u62e9\u5408\u9002\u7684Python\u7248\u672c\u3002\u901a\u5e38\u60c5\u51b5\u4e0b\uff0c\u9009\u62e9\u6700\u65b0\u7684\u7a33\u5b9a\u7248\u672c\u5373\u53ef\uff0c\u9664\u975e\u6709\u7279\u5b9a\u7684\u517c\u5bb9\u6027\u8981\u6c42\u3002<\/li>\n<li><strong>\u4e0b\u8f7d\u5b89\u88c5\u5305<\/strong>\uff1a\u70b9\u51fb\u4e0b\u8f7d\u6309\u94ae\uff0c\u83b7\u53d6\u9002\u5408\u4f60\u64cd\u4f5c\u7cfb\u7edf\u7684\u5b89\u88c5\u5305\u3002\u5bf9\u4e8eWindows\u7528\u6237\uff0c\u901a\u5e38\u662f\u4e00\u4e2a.exe\u6587\u4ef6\uff1b\u5bf9\u4e8emacOS\u7528\u6237\uff0c\u662f\u4e00\u4e2a.pkg\u6587\u4ef6\u3002<\/li>\n<\/ol>\n<p><p>\u63a5\u4e0b\u6765\uff0c\u8fdb\u884c\u5b89\u88c5\uff1a<\/p>\n<\/p>\n<ul>\n<li><strong>\u8fd0\u884c\u5b89\u88c5\u5305<\/strong>\uff1a\u53cc\u51fb\u4e0b\u8f7d\u7684\u5b89\u88c5\u5305\u6587\u4ef6\uff0c\u542f\u52a8\u5b89\u88c5\u7a0b\u5e8f\u3002<\/li>\n<li><strong>\u9009\u62e9\u5b89\u88c5\u9009\u9879<\/strong>\uff1a\u5728\u5b89\u88c5\u5411\u5bfc\u4e2d\uff0c\u5efa\u8bae\u52fe\u9009\u201cAdd Python to PATH\u201d\uff08\u5c06Python\u6dfb\u52a0\u5230\u7cfb\u7edf\u8def\u5f84\uff09\uff0c\u8fd9\u6837\u4f60\u53ef\u4ee5\u5728\u547d\u4ee4\u884c\u4e2d\u76f4\u63a5\u4f7f\u7528Python\u547d\u4ee4\u3002\u7136\u540e\u9009\u62e9\u201cInstall Now\u201d\uff08\u7acb\u5373\u5b89\u88c5\uff09\u6216\u201cCustomize installation\u201d\uff08\u81ea\u5b9a\u4e49\u5b89\u88c5\uff09\uff0c\u6839\u636e\u9700\u8981\u8fdb\u884c\u9009\u62e9\u3002<\/li>\n<li><strong>\u5b8c\u6210\u5b89\u88c5<\/strong>\uff1a\u7b49\u5f85\u5b89\u88c5\u5b8c\u6210\uff0c\u5b89\u88c5\u7a0b\u5e8f\u4f1a\u63d0\u793a\u6210\u529f\u4fe1\u606f\u3002<\/li>\n<\/ul>\n<p><p>\u5b89\u88c5\u5b8c\u6210\u540e\uff0c\u53ef\u4ee5\u901a\u8fc7\u547d\u4ee4\u884c\u9a8c\u8bc1\u5b89\u88c5\u662f\u5426\u6210\u529f\uff1a<\/p>\n<\/p>\n<ul>\n<li>\u6253\u5f00\u547d\u4ee4\u884c\uff08Windows\u7528\u6237\u4f7f\u7528cmd\u6216PowerShell\uff0cmacOS\/Linux\u7528\u6237\u4f7f\u7528\u7ec8\u7aef\uff09\u3002<\/li>\n<li>\u8f93\u5165<code>python --version<\/code>\uff0c\u5982\u679c\u663e\u793a\u51faPython\u7684\u7248\u672c\u53f7\uff0c\u8bf4\u660e\u5b89\u88c5\u6210\u529f\u3002<\/li>\n<\/ul>\n<p><p>\u63a5\u4e0b\u6765\uff0c\u6211\u4eec\u6df1\u5165\u63a2\u8ba8Python\u5b89\u88c5\u7684\u5176\u4ed6\u65b9\u6cd5\u3001\u53ef\u80fd\u9047\u5230\u7684\u95ee\u9898\u53ca\u5176\u89e3\u51b3\u65b9\u6848\u3002<\/p>\n<\/p>\n<p><h3>\u4e00\u3001\u901a\u8fc7\u5305\u7ba1\u7406\u5668\u5b89\u88c5Python<\/h3>\n<\/p>\n<p><h4>\u4f7f\u7528Homebrew\uff08\u9002\u7528\u4e8emacOS\uff09<\/h4>\n<\/p>\n<p><p>Homebrew\u662fmacOS\u4e0a\u7684\u4e00\u4e2a\u6d41\u884c\u7684\u5305\u7ba1\u7406\u5668\uff0c\u53ef\u4ee5\u5f88\u65b9\u4fbf\u5730\u5b89\u88c5Python\u3002<\/p>\n<\/p>\n<ol>\n<li><strong>\u5b89\u88c5Homebrew<\/strong>\uff1a\u5982\u679c\u4f60\u8fd8\u6ca1\u6709\u5b89\u88c5Homebrew\uff0c\u53ef\u4ee5\u5728\u7ec8\u7aef\u4e2d\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\uff1a\n<pre><code class=\"language-bash\">\/bin\/bash -c &quot;$(curl -fsSL https:\/\/raw.githubusercontent.com\/Homebrew\/install\/HEAD\/install.sh)&quot;<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li><strong>\u66f4\u65b0Homebrew<\/strong>\uff1a\u5b89\u88c5\u5b8c\u6210\u540e\uff0c\u786e\u4fddHomebrew\u662f\u6700\u65b0\u7684\uff1a\n<pre><code class=\"language-bash\">brew update<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li><strong>\u5b89\u88c5Python<\/strong>\uff1a\u4f7f\u7528Homebrew\u5b89\u88c5Python\uff1a\n<pre><code class=\"language-bash\">brew install python<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li><strong>\u9a8c\u8bc1\u5b89\u88c5<\/strong>\uff1a\u4f7f\u7528\u547d\u4ee4<code>python3 --version<\/code>\u6765\u786e\u8ba4Python\u5df2\u6210\u529f\u5b89\u88c5\u3002<\/li>\n<\/ol>\n<p><h4>\u4f7f\u7528Chocolatey\uff08\u9002\u7528\u4e8eWindows\uff09<\/h4>\n<\/p>\n<p><p>Chocolatey\u662fWindows\u4e0a\u7684\u4e00\u4e2a\u5305\u7ba1\u7406\u5668\uff0c\u7c7b\u4f3c\u4e8eHomebrew\u3002<\/p>\n<\/p>\n<ol>\n<li><strong>\u5b89\u88c5Chocolatey<\/strong>\uff1a\u6253\u5f00\u547d\u4ee4\u63d0\u793a\u7b26\uff08\u4ee5\u7ba1\u7406\u5458\u8eab\u4efd\uff09\uff0c\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\uff1a\n<pre><code class=\"language-powershell\">@&quot;%SystemRoot%\\System32\\WindowsPowerShell\\v1.0\\powershell.exe&quot; -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command &quot;iex ((New-Object System.Net.WebClient).DownloadString(&#39;https:\/\/chocolatey.org\/install.ps1&#39;))&quot; &amp;&amp; SET &quot;PATH=%PATH%;%ALLUSERSPROFILE%\\chocolatey\\bin&quot;<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li><strong>\u5b89\u88c5Python<\/strong>\uff1a\u901a\u8fc7Chocolatey\u5b89\u88c5Python\uff0c\u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\uff1a\n<pre><code class=\"language-powershell\">choco install python<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li><strong>\u9a8c\u8bc1\u5b89\u88c5<\/strong>\uff1a\u8fd0\u884c<code>python --version<\/code>\u6765\u68c0\u67e5Python\u662f\u5426\u5b89\u88c5\u6210\u529f\u3002<\/li>\n<\/ol>\n<p><h3>\u4e8c\u3001\u4f7f\u7528Anaconda\u5b89\u88c5Python<\/h3>\n<\/p>\n<p><p>Anaconda\u662f\u4e00\u4e2a\u9488\u5bf9\u79d1\u5b66\u8ba1\u7b97\u548c\u6570\u636e\u5206\u6790\u7684Python\u53d1\u884c\u7248\u672c\uff0c\u96c6\u6210\u4e86\u5927\u91cf\u7684Python\u5305\u548c\u5de5\u5177\u3002<\/p>\n<\/p>\n<ol>\n<li><strong>\u4e0b\u8f7dAnaconda<\/strong>\uff1a\u8bbf\u95ee<a href=\"https:\/\/www.anaconda.com\/products\/distribution\">Anaconda\u5b98\u7f51<\/a>\uff0c\u4e0b\u8f7d\u9002\u5408\u4f60\u64cd\u4f5c\u7cfb\u7edf\u7684Anaconda\u5b89\u88c5\u5305\u3002<\/li>\n<li><strong>\u5b89\u88c5Anaconda<\/strong>\uff1a\u8fd0\u884c\u4e0b\u8f7d\u7684\u5b89\u88c5\u5305\uff0c\u6309\u7167\u5b89\u88c5\u5411\u5bfc\u8fdb\u884c\u5b89\u88c5\u3002<\/li>\n<li><strong>\u8bbe\u7f6e\u73af\u5883\u53d8\u91cf<\/strong>\uff1a\u5b89\u88c5\u8fc7\u7a0b\u4e2d\uff0c\u53ef\u4ee5\u9009\u62e9\u662f\u5426\u5c06Anaconda\u6dfb\u52a0\u5230\u7cfb\u7edf\u8def\u5f84\uff0c\u5efa\u8bae\u52fe\u9009\u6b64\u9009\u9879\u3002<\/li>\n<li><strong>\u9a8c\u8bc1\u5b89\u88c5<\/strong>\uff1a\u6253\u5f00\u547d\u4ee4\u884c\uff0c\u8f93\u5165<code>conda --version<\/code>\uff0c\u786e\u8ba4Anaconda\u5b89\u88c5\u6210\u529f\u3002\u7136\u540e\uff0c\u53ef\u4ee5\u4f7f\u7528<code>conda list<\/code>\u67e5\u770b\u5df2\u5b89\u88c5\u7684Python\u5305\u3002<\/li>\n<\/ol>\n<p><h3>\u4e09\u3001\u5e38\u89c1\u95ee\u9898\u53ca\u89e3\u51b3\u65b9\u6848<\/h3>\n<\/p>\n<p><h4>1. \u5b89\u88c5\u540ePython\u547d\u4ee4\u65e0\u6548<\/h4>\n<\/p>\n<ul>\n<li><strong>\u95ee\u9898\u63cf\u8ff0<\/strong>\uff1a\u5b89\u88c5Python\u540e\uff0c\u5728\u547d\u4ee4\u884c\u4e2d\u8f93\u5165<code>python<\/code>\u6216<code>python3<\/code>\uff0c\u663e\u793a\u547d\u4ee4\u65e0\u6548\u3002<\/li>\n<li><strong>\u89e3\u51b3\u65b9\u6848<\/strong>\uff1a\u53ef\u80fd\u662fPython\u7684\u8def\u5f84\u672a\u6dfb\u52a0\u5230\u73af\u5883\u53d8\u91cf\u4e2d\u3002\u624b\u52a8\u5c06Python\u7684\u5b89\u88c5\u8def\u5f84\u6dfb\u52a0\u5230\u7cfb\u7edf\u7684PATH\u73af\u5883\u53d8\u91cf\u4e2d\uff0c\u5177\u4f53\u6b65\u9aa4\u56e0\u64cd\u4f5c\u7cfb\u7edf\u4e0d\u540c\u800c\u5f02\u3002<\/li>\n<\/ul>\n<p><h4>2. \u591a\u7248\u672cPython\u7684\u7ba1\u7406<\/h4>\n<\/p>\n<ul>\n<li><strong>\u95ee\u9898\u63cf\u8ff0<\/strong>\uff1a\u8ba1\u7b97\u673a\u4e0a\u5df2\u7ecf\u5b89\u88c5\u4e86\u591a\u4e2a\u7248\u672c\u7684Python\uff0c\u5bfc\u81f4\u7248\u672c\u51b2\u7a81\u3002<\/li>\n<li><strong>\u89e3\u51b3\u65b9\u6848<\/strong>\uff1a\u53ef\u4ee5\u4f7f\u7528<code>pyenv<\/code>\uff08\u9002\u7528\u4e8emacOS\u548cLinux\uff09\u6216<code>conda<\/code>\u73af\u5883\u6765\u7ba1\u7406\u4e0d\u540c\u7684Python\u7248\u672c\u3002\u901a\u8fc7\u8fd9\u4e9b\u5de5\u5177\u53ef\u4ee5\u65b9\u4fbf\u5730\u5207\u6362Python\u7248\u672c\u3002<\/li>\n<\/ul>\n<p><h4>3. SSL\u8bc1\u4e66\u95ee\u9898<\/h4>\n<\/p>\n<ul>\n<li><strong>\u95ee\u9898\u63cf\u8ff0<\/strong>\uff1a\u5728\u5b89\u88c5Python\u5305\u65f6\uff0c\u53ef\u80fd\u4f1a\u9047\u5230SSL\u8bc1\u4e66\u9519\u8bef\u3002<\/li>\n<li><strong>\u89e3\u51b3\u65b9\u6848<\/strong>\uff1a\u66f4\u65b0pip\u5230\u6700\u65b0\u7248\u672c\uff0c\u5e76\u786e\u4fdd\u7cfb\u7edf\u7684CA\u8bc1\u4e66\u662f\u6700\u65b0\u7684\u3002\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u547d\u4ee4\u66f4\u65b0pip\uff1a\n<pre><code class=\"language-bash\">python -m pip install --upgrade pip<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<\/ul>\n<p><h3>\u56db\u3001\u8865\u5145\uff1aPython\u5f00\u53d1\u73af\u5883\u7684\u914d\u7f6e<\/h3>\n<\/p>\n<p><p>\u5728\u5b89\u88c5Python\u4e4b\u540e\uff0c\u5efa\u8bae\u914d\u7f6e\u4e00\u4e2a\u826f\u597d\u7684\u5f00\u53d1\u73af\u5883\uff0c\u4ee5\u63d0\u9ad8\u5f00\u53d1\u6548\u7387\u3002<\/p>\n<\/p>\n<p><h4>1. \u4f7f\u7528\u865a\u62df\u73af\u5883<\/h4>\n<\/p>\n<ul>\n<li><strong>\u521b\u5efa\u865a\u62df\u73af\u5883<\/strong>\uff1a\u4f7f\u7528<code>venv<\/code>\u6a21\u5757\u6765\u521b\u5efa\u865a\u62df\u73af\u5883\uff0c\u9694\u79bb\u9879\u76ee\u7684\u4f9d\u8d56\u3002\n<pre><code class=\"language-bash\">python -m venv myenv<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li><strong>\u6fc0\u6d3b\u865a\u62df\u73af\u5883<\/strong>\uff1a\n<ul>\n<li>Windows:\n<pre><code class=\"language-bash\">myenv\\Scripts\\activate<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<li>macOS\/Linux:\n<pre><code class=\"language-bash\">source myenv\/bin\/activate<\/p>\n<p><\/code><\/pre>\n<\/p>\n<\/li>\n<\/ul>\n<\/li>\n<li><strong>\u9000\u51fa\u865a\u62df\u73af\u5883<\/strong>\uff1a\u4f7f\u7528\u547d\u4ee4<code>deactivate<\/code>\u3002<\/li>\n<\/ul>\n<p><h4>2. \u9009\u62e9\u5408\u9002\u7684IDE<\/h4>\n<\/p>\n<ul>\n<li><strong>PyCharm<\/strong>\uff1a\u529f\u80fd\u5f3a\u5927\u7684Python\u96c6\u6210\u5f00\u53d1\u73af\u5883\uff0c\u9002\u5408\u5927\u578b\u9879\u76ee\u5f00\u53d1\u3002<\/li>\n<li><strong>Visual Studio Code<\/strong>\uff1a\u8f7b\u91cf\u7ea7\u4e14\u6269\u5c55\u6027\u5f3a\u7684\u7f16\u8f91\u5668\uff0c\u914d\u5408Python\u63d2\u4ef6\u4e5f\u5f88\u9002\u5408Python\u5f00\u53d1\u3002<\/li>\n<li><strong>Jupyter Notebook<\/strong>\uff1a\u9002\u5408\u6570\u636e\u5206\u6790\u548c<a href=\"https:\/\/docs.pingcode.com\/ask\/59192.html\" target=\"_blank\">\u673a\u5668\u5b66\u4e60<\/a>\u4efb\u52a1\u7684\u4ea4\u4e92\u5f0f\u73af\u5883\u3002<\/li>\n<\/ul>\n<p><h4>3. \u5b89\u88c5\u5e38\u7528\u7684Python\u5305<\/h4>\n<\/p>\n<p><p>\u6839\u636e\u9879\u76ee\u9700\u8981\uff0c\u5b89\u88c5\u4e00\u4e9b\u5e38\u7528\u7684Python\u5305\u3002\u4f8b\u5982\uff0c\u79d1\u5b66\u8ba1\u7b97\u548c\u6570\u636e\u5206\u6790\u5e38\u7528\u7684<code>numpy<\/code>\u3001<code>pandas<\/code>\u3001<code>matplotlib<\/code>\u7b49\u3002<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install numpy pandas matplotlib<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><h3>\u4e94\u3001\u603b\u7ed3<\/h3>\n<\/p>\n<p><p>\u5b89\u88c5Python\u6709\u591a\u79cd\u65b9\u6cd5\uff0c\u6839\u636e\u4e0d\u540c\u7684\u9700\u6c42\u548c\u64cd\u4f5c\u7cfb\u7edf\uff0c\u9009\u62e9\u6700\u9002\u5408\u7684\u65b9\u5f0f\u3002\u901a\u8fc7Python\u5b98\u7f51\u4e0b\u8f7d\u5b89\u88c5\u5305\u662f\u6700\u76f4\u63a5\u7684\u65b9\u5f0f\uff0c\u800c\u4f7f\u7528\u5305\u7ba1\u7406\u5668\u548cAnaconda\u5219\u63d0\u4f9b\u4e86\u66f4\u591a\u7684\u7075\u6d3b\u6027\u548c\u529f\u80fd\u3002\u5b89\u88c5\u540e\uff0c\u901a\u8fc7\u914d\u7f6e\u865a\u62df\u73af\u5883\u548c\u9009\u62e9\u5408\u9002\u7684IDE\uff0c\u53ef\u4ee5\u6253\u9020\u4e00\u4e2a\u9ad8\u6548\u7684Python\u5f00\u53d1\u73af\u5883\u3002\u65e0\u8bba\u9009\u62e9\u54ea\u79cd\u5b89\u88c5\u65b9\u5f0f\uff0c\u786e\u4fddPython\u7684\u8def\u5f84\u6b63\u786e\u914d\u7f6e\uff0c\u5e76\u5b9a\u671f\u66f4\u65b0\u5de5\u5177\u548c\u5305\uff0c\u4ee5\u4fdd\u6301\u5f00\u53d1\u73af\u5883\u7684\u7a33\u5b9a\u548c\u5b89\u5168\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u9009\u62e9\u9002\u5408\u81ea\u5df1\u7cfb\u7edf\u7684Python\u7248\u672c\uff1f<\/strong><br \/>\u5728\u9009\u62e9Python\u7248\u672c\u65f6\uff0c\u7528\u6237\u9700\u8981\u8003\u8651\u81ea\u5df1\u7684\u64cd\u4f5c\u7cfb\u7edf\uff08Windows\u3001macOS\u6216Linux\uff09\u4ee5\u53ca\u6240\u9700\u7684Python\u529f\u80fd\u3002\u901a\u5e38\uff0c\u6700\u65b0\u7684\u7a33\u5b9a\u7248\u672c\u4f1a\u63d0\u4f9b\u66f4\u591a\u7684\u529f\u80fd\u548c\u5b89\u5168\u66f4\u65b0\uff0c\u4f46\u67d0\u4e9b\u9879\u76ee\u53ef\u80fd\u9700\u8981\u4f9d\u8d56\u7279\u5b9a\u7684\u65e7\u7248\u672c\u3002\u5728\u51b3\u5b9a\u4e4b\u524d\uff0c\u67e5\u9605\u9879\u76ee\u7684\u6587\u6863\u6216\u793e\u533a\u5efa\u8bae\u662f\u975e\u5e38\u91cd\u8981\u7684\u3002<\/p>\n<p><strong>\u5b89\u88c5Python\u65f6\u662f\u5426\u9700\u8981\u914d\u7f6e\u73af\u5883\u53d8\u91cf\uff1f<\/strong><br \/>\u662f\u7684\uff0c\u914d\u7f6e\u73af\u5883\u53d8\u91cf\u80fd\u591f\u8ba9\u7528\u6237\u5728\u547d\u4ee4\u884c\u4e2d\u76f4\u63a5\u4f7f\u7528Python\u547d\u4ee4\uff0c\u800c\u4e0d\u9700\u8981\u6bcf\u6b21\u90fd\u8f93\u5165\u5b8c\u6574\u8def\u5f84\u3002\u5728\u5b89\u88c5\u8fc7\u7a0b\u4e2d\uff0c\u8bb8\u591a\u5b89\u88c5\u7a0b\u5e8f\u4f1a\u63d0\u4f9b\u81ea\u52a8\u914d\u7f6e\u73af\u5883\u53d8\u91cf\u7684\u9009\u9879\uff0c\u7528\u6237\u5e94\u8be5\u786e\u4fdd\u9009\u62e9\u6b64\u9009\u9879\uff0c\u4ee5\u4fbf\u80fd\u65b9\u4fbf\u5730\u4f7f\u7528Python\u3002<\/p>\n<p><strong>\u5b89\u88c5Python\u540e\u5982\u4f55\u9a8c\u8bc1\u5b89\u88c5\u662f\u5426\u6210\u529f\uff1f<\/strong><br \/>\u7528\u6237\u53ef\u4ee5\u901a\u8fc7\u6253\u5f00\u547d\u4ee4\u884c\u6216\u7ec8\u7aef\u7a97\u53e3\uff0c\u8f93\u5165<code>python --version<\/code>\u6216<code>python3 --version<\/code>\u547d\u4ee4\u6765\u68c0\u67e5Python\u662f\u5426\u5b89\u88c5\u6210\u529f\u3002\u5982\u679c\u7cfb\u7edf\u8fd4\u56de\u4e86Python\u7684\u7248\u672c\u53f7\uff0c\u8bf4\u660e\u5b89\u88c5\u5df2\u7ecf\u6210\u529f\u3002\u5982\u679c\u6ca1\u6709\u8fd4\u56de\u7248\u672c\u53f7\uff0c\u53ef\u80fd\u9700\u8981\u68c0\u67e5\u73af\u5883\u53d8\u91cf\u7684\u8bbe\u7f6e\u6216\u91cd\u65b0\u5b89\u88c5\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u88c5Python\u7684\u65b9\u6cd5\u5305\u62ec\uff1a\u4f7f\u7528Python\u5b98\u7f51\u4e0b\u8f7d\u5b89\u88c5\u5305\u3001\u4f7f\u7528\u5305\u7ba1\u7406\u5668\uff08\u5982Homebrew\u6216Chocolate [&hellip;]","protected":false},"author":3,"featured_media":923097,"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\/923093"}],"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=923093"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/923093\/revisions"}],"predecessor-version":[{"id":923101,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/923093\/revisions\/923101"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/923097"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=923093"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=923093"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=923093"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}