{"id":923502,"date":"2024-12-26T14:50:38","date_gmt":"2024-12-26T06:50:38","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/923502.html"},"modified":"2024-12-26T14:50:40","modified_gmt":"2024-12-26T06:50:40","slug":"python%e5%a6%82%e4%bd%95%e5%86%99%e7%a8%8b%e5%ba%8f","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/923502.html","title":{"rendered":"python\u5982\u4f55\u5199\u7a0b\u5e8f"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/24211546\/f4cd4ad1-3e72-49a9-b1f6-e023884abff9.webp\" alt=\"python\u5982\u4f55\u5199\u7a0b\u5e8f\" \/><\/p>\n<p><p> <strong>\u7f16\u5199Python\u7a0b\u5e8f\u7684\u6838\u5fc3\u6b65\u9aa4\u5305\u62ec\uff1a\u5b89\u88c5Python\u73af\u5883\u3001\u9009\u62e9\u5408\u9002\u7684IDE\u6216\u6587\u672c\u7f16\u8f91\u5668\u3001\u7f16\u5199\u4ee3\u7801\u5e76\u4fdd\u5b58\u4e3a.py\u6587\u4ef6\u3001\u6267\u884c\u548c\u8c03\u8bd5\u4ee3\u7801\u3001\u4e0d\u65ad\u4f18\u5316\u548c\u91cd\u6784\u4ee3\u7801\u3002<\/strong>\u4e0b\u9762\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u5982\u4f55\u901a\u8fc7\u8fd9\u4e9b\u6b65\u9aa4\u6765\u7f16\u5199\u4e00\u4e2aPython\u7a0b\u5e8f\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001\u5b89\u88c5Python\u73af\u5883<\/p>\n<\/p>\n<p><p>\u8981\u7f16\u5199Python\u7a0b\u5e8f\uff0c\u9996\u5148\u9700\u8981\u5728\u8ba1\u7b97\u673a\u4e0a\u5b89\u88c5Python\u89e3\u91ca\u5668\u3002Python\u662f\u4e00\u79cd\u5f00\u6e90\u7684\u7f16\u7a0b\u8bed\u8a00\uff0c\u53ef\u4ee5\u4ecePython\u5b98\u65b9\u7f51\u7ad9\uff08python.org\uff09\u4e0b\u8f7d\u5e76\u5b89\u88c5\u3002\u5b89\u88c5\u65f6\u5efa\u8bae\u9009\u62e9\u6700\u65b0\u7a33\u5b9a\u7248\u672c\uff0c\u5e76\u5728\u5b89\u88c5\u8fc7\u7a0b\u4e2d\u52fe\u9009\u201cAdd Python to PATH\u201d\u9009\u9879\uff0c\u4ee5\u4fbf\u5728\u547d\u4ee4\u884c\u4e2d\u76f4\u63a5\u4f7f\u7528Python\u547d\u4ee4\u3002<\/p>\n<\/p>\n<p><p>\u4e8c\u3001\u9009\u62e9\u5408\u9002\u7684IDE\u6216\u6587\u672c\u7f16\u8f91\u5668<\/p>\n<\/p>\n<p><p>\u9009\u62e9\u4e00\u4e2a\u5408\u9002\u7684IDE\uff08\u96c6\u6210\u5f00\u53d1\u73af\u5883\uff09\u6216\u6587\u672c\u7f16\u8f91\u5668\u6709\u52a9\u4e8e\u63d0\u9ad8\u7f16\u7a0b\u6548\u7387\u3002\u5e38\u7528\u7684Python\u5f00\u53d1\u5de5\u5177\u6709PyCharm\u3001Visual Studio Code\u3001Atom\u3001Sublime Text\u7b49\u3002IDE\u901a\u5e38\u63d0\u4f9b\u4ee3\u7801\u8865\u5168\u3001\u8bed\u6cd5\u9ad8\u4eae\u3001\u8c03\u8bd5\u5de5\u5177\u7b49\u529f\u80fd\uff0c\u800c\u6587\u672c\u7f16\u8f91\u5668\u66f4\u8f7b\u91cf\uff0c\u9002\u5408\u7b80\u5355\u7684\u811a\u672c\u7f16\u5199\u3002<\/p>\n<\/p>\n<p><p>\u4e09\u3001\u7f16\u5199\u4ee3\u7801\u5e76\u4fdd\u5b58\u4e3a.py\u6587\u4ef6<\/p>\n<\/p>\n<p><p>\u5728\u9009\u62e9\u597d\u7684IDE\u6216\u6587\u672c\u7f16\u8f91\u5668\u4e2d\uff0c\u65b0\u5efa\u4e00\u4e2a\u6587\u4ef6\u5e76\u7f16\u5199Python\u4ee3\u7801\u3002Python\u7684\u8bed\u6cd5\u7b80\u6d01\uff0c\u9002\u5408\u521d\u5b66\u8005\u3002\u4ee3\u7801\u7f16\u5199\u5b8c\u6bd5\u540e\uff0c\u5c06\u6587\u4ef6\u4fdd\u5b58\u4e3a\u4ee5.py\u7ed3\u5c3e\u7684\u6587\u4ef6\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u521b\u5efa\u4e00\u4e2a\u7b80\u5355\u7684\u201cHello, World!\u201d\u7a0b\u5e8f\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\">print(&quot;Hello, World!&quot;)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4fdd\u5b58\u4e3a<code>hello.py<\/code>\u3002<\/p>\n<\/p>\n<p><p>\u56db\u3001\u6267\u884c\u548c\u8c03\u8bd5\u4ee3\u7801<\/p>\n<\/p>\n<p><p>\u8981\u6267\u884cPython\u7a0b\u5e8f\uff0c\u53ef\u4ee5\u5728\u547d\u4ee4\u884c\u4e2d\u5bfc\u822a\u5230\u6587\u4ef6\u6240\u5728\u7684\u76ee\u5f55\uff0c\u7136\u540e\u8f93\u5165<code>python hello.py<\/code>\u3002\u8fd9\u5c06\u8fd0\u884c\u4f60\u7684\u7a0b\u5e8f\u5e76\u5728\u7ec8\u7aef\u4e2d\u8f93\u51fa\u201cHello, World!\u201d\u3002<\/p>\n<\/p>\n<p><p>\u5728\u5f00\u53d1\u8fc7\u7a0b\u4e2d\uff0c\u8c03\u8bd5\u662f\u5fc5\u4e0d\u53ef\u5c11\u7684\u6b65\u9aa4\u3002Python\u7684\u8c03\u8bd5\u5de5\u5177\u5982<code>pdb<\/code>\u3001\u4ee5\u53caIDE\u81ea\u5e26\u7684\u8c03\u8bd5\u529f\u80fd\uff0c\u53ef\u4ee5\u5e2e\u52a9\u5f00\u53d1\u8005\u627e\u51fa\u4ee3\u7801\u4e2d\u7684\u9519\u8bef\u3002\u901a\u8fc7\u9010\u884c\u6267\u884c\u4ee3\u7801\uff0c\u68c0\u67e5\u53d8\u91cf\u7684\u503c\uff0c\u53ef\u4ee5\u66f4\u597d\u5730\u7406\u89e3\u7a0b\u5e8f\u7684\u6267\u884c\u6d41\u7a0b\u3002<\/p>\n<\/p>\n<p><p>\u4e94\u3001\u4e0d\u65ad\u4f18\u5316\u548c\u91cd\u6784\u4ee3\u7801<\/p>\n<\/p>\n<p><p>\u7f16\u5199\u5b8c\u521d\u6b65\u7684\u7a0b\u5e8f\u540e\uff0c\u5e94\u8be5\u8003\u8651\u5bf9\u4ee3\u7801\u8fdb\u884c\u4f18\u5316\u548c\u91cd\u6784\u3002\u4f18\u5316\u5305\u62ec\u63d0\u9ad8\u4ee3\u7801\u7684\u6267\u884c\u6548\u7387\u3001\u51cf\u5c11\u8d44\u6e90\u6d88\u8017\u7b49\uff1b\u91cd\u6784\u5219\u662f\u4e3a\u4e86\u63d0\u9ad8\u4ee3\u7801\u7684\u53ef\u8bfb\u6027\u548c\u53ef\u7ef4\u62a4\u6027\u3002\u53ef\u4ee5\u901a\u8fc7\u4ee5\u4e0b\u51e0\u79cd\u65b9\u6cd5\u8fdb\u884c\u4f18\u5316\u548c\u91cd\u6784\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u4f7f\u7528\u51fd\u6570\u548c\u6a21\u5757<\/strong>\uff1a\u5c06\u91cd\u590d\u7684\u4ee3\u7801\u6bb5\u62bd\u8c61\u4e3a\u51fd\u6570\uff0c\u63d0\u9ad8\u4ee3\u7801\u7684\u590d\u7528\u6027\uff1b\u5c06\u76f8\u5173\u529f\u80fd\u5c01\u88c5\u5728\u6a21\u5757\u4e2d\uff0c\u589e\u5f3a\u7a0b\u5e8f\u7684\u7ed3\u6784\u5316\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u9075\u5faaPEP 8\u7f16\u7801\u89c4\u8303<\/strong>\uff1aPEP 8\u662fPython\u7684\u7f16\u7801\u98ce\u683c\u6307\u5357\uff0c\u9075\u5faa\u8fd9\u4e9b\u89c4\u8303\u53ef\u4ee5\u63d0\u9ad8\u4ee3\u7801\u7684\u53ef\u8bfb\u6027\u548c\u4e00\u81f4\u6027\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u4f7f\u7528\u5f02\u5e38\u5904\u7406<\/strong>\uff1a\u901a\u8fc7<code>try-except<\/code>\u8bed\u53e5\u6355\u83b7\u5f02\u5e38\uff0c\u63d0\u9ad8\u7a0b\u5e8f\u7684\u5065\u58ee\u6027\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u5229\u7528Python\u6807\u51c6\u5e93\u548c\u7b2c\u4e09\u65b9\u5e93<\/strong>\uff1aPython\u7684\u6807\u51c6\u5e93\u975e\u5e38\u4e30\u5bcc\uff0c\u7b2c\u4e09\u65b9\u5e93\u4e5f\u80fd\u63d0\u4f9b\u5927\u91cf\u529f\u80fd\uff0c\u5408\u7406\u5229\u7528\u53ef\u4ee5\u51cf\u5c11\u5f00\u53d1\u65f6\u95f4\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u516d\u3001\u6df1\u5165\u5b66\u4e60Python\u7279\u6027<\/p>\n<\/p>\n<p><p>\u5728\u719f\u6089\u4e86\u57fa\u672c\u7684Python\u7f16\u7a0b\u4e4b\u540e\uff0c\u53ef\u4ee5\u6df1\u5165\u5b66\u4e60Python\u7684\u4e00\u4e9b\u9ad8\u7ea7\u7279\u6027\uff0c\u4ee5\u8fdb\u4e00\u6b65\u63d0\u9ad8\u7f16\u7a0b\u6c34\u5e73\u3002<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u9762\u5411\u5bf9\u8c61\u7f16\u7a0b\uff08OOP\uff09<\/strong>\uff1aPython\u662f\u4e00\u79cd\u9762\u5411\u5bf9\u8c61\u7684\u8bed\u8a00\uff0c\u7406\u89e3\u7c7b\u4e0e\u5bf9\u8c61\u3001\u7ee7\u627f\u3001\u591a\u6001\u7b49\u6982\u5ff5\uff0c\u53ef\u4ee5\u5e2e\u52a9\u5f00\u53d1\u66f4\u590d\u6742\u7684\u5e94\u7528\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u51fd\u6570\u5f0f\u7f16\u7a0b<\/strong>\uff1aPython\u652f\u6301\u51fd\u6570\u5f0f\u7f16\u7a0b\u98ce\u683c\uff0c\u7406\u89e3\u9ad8\u9636\u51fd\u6570\u3001\u533f\u540d\u51fd\u6570\uff08lambda\uff09\u3001\u751f\u6210\u5668\u548c\u8fed\u4ee3\u5668\u7b49\u6982\u5ff5\uff0c\u53ef\u4ee5\u7f16\u5199\u66f4\u7b80\u6d01\u7684\u4ee3\u7801\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u5f02\u6b65\u7f16\u7a0b<\/strong>\uff1aPython 3\u5f15\u5165\u4e86<code>asyncio<\/code>\u6a21\u5757\uff0c\u652f\u6301\u5f02\u6b65\u7f16\u7a0b\uff0c\u53ef\u4ee5\u7528\u6765\u5904\u7406I\/O\u5bc6\u96c6\u578b\u4efb\u52a1\uff0c\u63d0\u9ad8\u7a0b\u5e8f\u7684\u5e76\u53d1\u80fd\u529b\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u5143\u7f16\u7a0b<\/strong>\uff1a\u901a\u8fc7\u7406\u89e3\u88c5\u9970\u5668\u548c\u5143\u7c7b\uff0c\u53ef\u4ee5\u52a8\u6001\u5730\u4fee\u6539\u4ee3\u7801\u7684\u884c\u4e3a\uff0c\u63d0\u9ad8\u7a0b\u5e8f\u7684\u7075\u6d3b\u6027\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e03\u3001\u53c2\u4e0e\u5f00\u6e90\u9879\u76ee\u548c\u793e\u533a<\/p>\n<\/p>\n<p><p>\u53c2\u4e0e\u5f00\u6e90\u9879\u76ee\u662f\u63d0\u9ad8\u7f16\u7a0b\u80fd\u529b\u7684\u6709\u6548\u9014\u5f84\u3002\u901a\u8fc7\u4e3a\u5f00\u6e90\u9879\u76ee\u8d21\u732e\u4ee3\u7801\uff0c\u53ef\u4ee5\u5b66\u4e60\u5230\u5176\u4ed6\u5f00\u53d1\u8005\u7684\u7f16\u7a0b\u6280\u5de7\uff0c\u5e76\u79ef\u7d2f\u5b9e\u9645\u5f00\u53d1\u7ecf\u9a8c\u3002\u6b64\u5916\uff0c\u52a0\u5165Python\u793e\u533a\uff0c\u53c2\u4e0e\u8ba8\u8bba\u548c\u5206\u4eab\uff0c\u6709\u52a9\u4e8e\u62d3\u5c55\u89c6\u91ce\uff0c\u83b7\u53d6\u66f4\u591a\u5b66\u4e60\u8d44\u6e90\u3002<\/p>\n<\/p>\n<p><p>\u516b\u3001\u7f16\u5199\u6587\u6863\u548c\u6d4b\u8bd5<\/p>\n<\/p>\n<p><p>\u7f16\u5199\u6e05\u6670\u7684\u6587\u6863\u548c\u6d4b\u8bd5\u7528\u4f8b\u662f\u7a0b\u5e8f\u5f00\u53d1\u7684\u826f\u597d\u4e60\u60ef\u3002\u6587\u6863\u53ef\u4ee5\u5e2e\u52a9\u4ed6\u4eba\uff08\u4ee5\u53ca\u672a\u6765\u7684\u81ea\u5df1\uff09\u7406\u89e3\u7a0b\u5e8f\u7684\u529f\u80fd\u548c\u4f7f\u7528\u65b9\u6cd5\uff0c\u800c\u6d4b\u8bd5\u7528\u4f8b\u53ef\u4ee5\u786e\u4fdd\u7a0b\u5e8f\u5728\u4fee\u6539\u540e\u4ecd\u7136\u4fdd\u6301\u6b63\u786e\u6027\u3002<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u6587\u6863\u7f16\u5199<\/strong>\uff1a\u53ef\u4ee5\u4f7f\u7528\u6587\u6863\u5b57\u7b26\u4e32\uff08docstring\uff09\u6765\u4e3a\u51fd\u6570\u3001\u7c7b\u548c\u6a21\u5757\u6dfb\u52a0\u8bf4\u660e\uff0cPython\u7684<code>pydoc<\/code>\u5de5\u5177\u53ef\u4ee5\u81ea\u52a8\u751f\u6210\u6587\u6863\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u5355\u5143\u6d4b\u8bd5<\/strong>\uff1a\u4f7f\u7528Python\u7684<code>unittest<\/code>\u6a21\u5757\u7f16\u5199\u5355\u5143\u6d4b\u8bd5\uff0c\u786e\u4fdd\u6bcf\u4e2a\u529f\u80fd\u5355\u5143\u80fd\u591f\u6b63\u5e38\u8fd0\u884c\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e5d\u3001\u90e8\u7f72\u548c\u53d1\u5e03<\/p>\n<\/p>\n<p><p>\u5f53\u7a0b\u5e8f\u5f00\u53d1\u5b8c\u6210\u540e\uff0c\u53ef\u4ee5\u8003\u8651\u5c06\u5176\u90e8\u7f72\u548c\u53d1\u5e03\u3002\u5bf9\u4e8eWeb\u5e94\u7528\uff0c\u53ef\u4ee5\u4f7f\u7528Web\u670d\u52a1\u5668\u5982Nginx\u3001Apache\u6765\u90e8\u7f72\uff1b\u5bf9\u4e8e\u684c\u9762\u5e94\u7528\uff0c\u53ef\u4ee5\u6253\u5305\u6210\u53ef\u6267\u884c\u6587\u4ef6\u53d1\u5e03\u7ed9\u7528\u6237\u3002<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u90e8\u7f72Web\u5e94\u7528<\/strong>\uff1a\u53ef\u4ee5\u4f7f\u7528Docker\u5bb9\u5668\u5316\u5e94\u7528\uff0c\u7b80\u5316\u90e8\u7f72\u6d41\u7a0b\uff1b\u4f7f\u7528\u4e91\u670d\u52a1\u5e73\u53f0\u5982AWS\u3001Azure\u3001Heroku\u7b49\uff0c\u53ef\u4ee5\u5feb\u901f\u4e0a\u7ebf\u5e94\u7528\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u53d1\u5e03\u684c\u9762\u5e94\u7528<\/strong>\uff1a\u4f7f\u7528<code>PyInstaller<\/code>\u6216<code>cx_Freeze<\/code>\u5c06Python\u811a\u672c\u6253\u5305\u4e3a\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u65b9\u4fbf\u7528\u6237\u5b89\u88c5\u548c\u4f7f\u7528\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u5341\u3001\u6301\u7eed\u5b66\u4e60\u548c\u66f4\u65b0<\/p>\n<\/p>\n<p><p>\u7f16\u7a0b\u6280\u672f\u65e5\u65b0\u6708\u5f02\uff0c\u4e0d\u65ad\u5b66\u4e60\u65b0\u77e5\u8bc6\u662f\u4fdd\u6301\u7ade\u4e89\u529b\u7684\u5173\u952e\u3002\u53ef\u4ee5\u901a\u8fc7\u9605\u8bfb\u4e66\u7c4d\u3001\u53c2\u52a0\u5728\u7ebf\u8bfe\u7a0b\u3001\u5173\u6ce8\u6280\u672f\u535a\u5ba2\u548c\u793e\u533a\u7b49\u65b9\u5f0f\uff0c\u6301\u7eed\u5b66\u4e60Python\u53ca\u5176\u76f8\u5173\u6280\u672f\u3002<\/p>\n<\/p>\n<p><p>\u603b\u4e4b\uff0c\u7f16\u5199Python\u7a0b\u5e8f\u9700\u8981\u638c\u63e1\u57fa\u7840\u8bed\u6cd5\u3001\u9009\u62e9\u5408\u9002\u7684\u5f00\u53d1\u5de5\u5177\u3001\u4e0d\u65ad\u4f18\u5316\u548c\u91cd\u6784\u4ee3\u7801\u3001\u6df1\u5165\u5b66\u4e60\u9ad8\u7ea7\u7279\u6027\uff0c\u5e76\u53c2\u4e0e\u793e\u533a\u6d3b\u52a8\u4ee5\u83b7\u53d6\u66f4\u591a\u7ecf\u9a8c\u548c\u8d44\u6e90\u3002\u901a\u8fc7\u6301\u7eed\u5b66\u4e60\u548c\u5b9e\u8df5\uff0c\u53ef\u4ee5\u4e0d\u65ad\u63d0\u5347\u81ea\u5df1\u7684\u7f16\u7a0b\u80fd\u529b\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u5f00\u59cb\u5b66\u4e60Python\u7f16\u7a0b\u8bed\u8a00\uff1f<\/strong><br \/>\u5b66\u4e60Python\u7f16\u7a0b\u8bed\u8a00\u7684\u6700\u4f73\u65b9\u6cd5\u662f\u4ece\u57fa\u7840\u77e5\u8bc6\u5165\u624b\uff0c\u638c\u63e1\u8bed\u6cd5\u3001\u6570\u636e\u7c7b\u578b\u548c\u63a7\u5236\u7ed3\u6784\u3002\u53ef\u4ee5\u901a\u8fc7\u5728\u7ebf\u8bfe\u7a0b\u3001\u4e66\u7c4d\u6216\u89c6\u9891\u6559\u7a0b\u6765\u5b66\u4e60\u3002\u63a8\u8350\u7684\u5b66\u4e60\u8d44\u6e90\u5305\u62ec\u300aPython Crash Course\u300b\u548cCoursera\u4e0a\u7684Python\u76f8\u5173\u8bfe\u7a0b\u3002\u540c\u65f6\uff0c\u52a8\u624b\u5b9e\u8df5\u975e\u5e38\u91cd\u8981\uff0c\u53ef\u4ee5\u5c1d\u8bd5\u89e3\u51b3\u7b80\u5355\u7684\u7f16\u7a0b\u9898\u76ee\u6216\u521b\u5efa\u5c0f\u9879\u76ee\u6765\u5de9\u56fa\u6240\u5b66\u77e5\u8bc6\u3002<\/p>\n<p><strong>Python\u6709\u54ea\u4e9b\u5e38\u7528\u7684\u5f00\u53d1\u73af\u5883\u548c\u5de5\u5177\uff1f<\/strong><br \/>\u5728Python\u5f00\u53d1\u4e2d\uff0c\u6709\u591a\u79cd\u5f00\u53d1\u73af\u5883\u548c\u5de5\u5177\u53ef\u4f9b\u9009\u62e9\u3002\u5e38\u7528\u7684IDE\u5305\u62ecPyCharm\u3001Visual Studio Code\u548cJupyter Notebook\u3002PyCharm\u63d0\u4f9b\u4e86\u4e30\u5bcc\u7684\u529f\u80fd\uff0c\u9002\u5408\u5927\u578b\u9879\u76ee\u7684\u5f00\u53d1\uff1b\u800cVisual Studio Code\u5219\u8f7b\u91cf\u7ea7\u4e14\u652f\u6301\u591a\u79cd\u63d2\u4ef6\uff0c\u975e\u5e38\u9002\u5408\u5c0f\u578b\u9879\u76ee\u548c\u5feb\u901f\u5f00\u53d1\u3002Jupyter Notebook\u9002\u5408\u6570\u636e\u5206\u6790\u548c\u53ef\u89c6\u5316\uff0c\u80fd\u591f\u5b9e\u73b0\u4ea4\u4e92\u5f0f\u7f16\u7a0b\u3002<\/p>\n<p><strong>\u5982\u4f55\u8c03\u8bd5Python\u7a0b\u5e8f\u4ee5\u89e3\u51b3\u9519\u8bef\uff1f<\/strong><br \/>\u8c03\u8bd5Python\u7a0b\u5e8f\u53ef\u4ee5\u4f7f\u7528\u591a\u79cd\u65b9\u6cd5\u3002\u9996\u5148\uff0c\u5229\u7528Python\u5185\u7f6e\u7684<code>print()<\/code>\u51fd\u6570\u5728\u5173\u952e\u4f4d\u7f6e\u8f93\u51fa\u53d8\u91cf\u503c\uff0c\u4ece\u800c\u8ffd\u8e2a\u7a0b\u5e8f\u7684\u6267\u884c\u6d41\u7a0b\u3002\u5176\u6b21\uff0c\u4f7f\u7528Python\u7684<code>pdb<\/code>\u8c03\u8bd5\u5668\u80fd\u591f\u9010\u884c\u6267\u884c\u4ee3\u7801\uff0c\u5e2e\u52a9\u8bc6\u522b\u95ee\u9898\u6240\u5728\u3002\u6b64\u5916\uff0c\u8bb8\u591aIDE\u63d0\u4f9b\u4e86\u56fe\u5f62\u5316\u8c03\u8bd5\u5de5\u5177\uff0c\u53ef\u4ee5\u8bbe\u7f6e\u65ad\u70b9\uff0c\u9010\u6b65\u6267\u884c\u4ee3\u7801\uff0c\u4ee5\u4fbf\u66f4\u76f4\u89c2\u5730\u53d1\u73b0\u548c\u4fee\u590d\u9519\u8bef\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u7f16\u5199Python\u7a0b\u5e8f\u7684\u6838\u5fc3\u6b65\u9aa4\u5305\u62ec\uff1a\u5b89\u88c5Python\u73af\u5883\u3001\u9009\u62e9\u5408\u9002\u7684IDE\u6216\u6587\u672c\u7f16\u8f91\u5668\u3001\u7f16\u5199\u4ee3\u7801\u5e76\u4fdd\u5b58\u4e3a.py [&hellip;]","protected":false},"author":3,"featured_media":923508,"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\/923502"}],"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=923502"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/923502\/revisions"}],"predecessor-version":[{"id":923511,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/923502\/revisions\/923511"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/923508"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=923502"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=923502"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=923502"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}