{"id":25,"date":"2025-09-25T09:12:01","date_gmt":"2025-09-25T01:12:01","guid":{"rendered":"http:\/\/www.pyteam.cn\/?p=25"},"modified":"2025-10-09T16:23:32","modified_gmt":"2025-10-09T08:23:32","slug":"%e4%be%8b4%e7%ad%89%e8%be%b9%e4%b8%89%e8%a7%92%e5%bd%a2","status":"publish","type":"post","link":"http:\/\/www.pyteam.cn\/index.php\/2025\/09\/25\/%e4%be%8b4%e7%ad%89%e8%be%b9%e4%b8%89%e8%a7%92%e5%bd%a2\/","title":{"rendered":"\u4f8b4\u7b49\u8fb9\u4e09\u89d2\u5f62"},"content":{"rendered":"\n<div class=\"wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:clamp(18px, 1.125rem, 27px);font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#90A4AE;--cbp-line-number-width:calc(1 * 0.6 * 1.125rem);--cbp-line-highlight-color:rgba(96, 180, 222, 0.2);line-height:clamp(26px, 1.625rem, 39px);--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:flex;align-items:center;padding:10px 0px 10px 16px;margin-bottom:-2px;width:100%;text-align:left;background-color:#ededed;color:#8198a3\">Python<\/span><span role=\"button\" tabindex=\"0\" style=\"color:#90A4AE;display:none\" aria-label=\"\u590d\u5236\" class=\"code-block-pro-copy-button\"><pre class=\"code-block-pro-copy-button-pre\" aria-hidden=\"true\"><textarea class=\"code-block-pro-copy-button-textarea\" tabindex=\"-1\" aria-hidden=\"true\" readonly>import turtle          #\u4f7f\u7528import\u8bed\u53e5\u5bfc\u5165turtle\u7ed8\u56fe\u5e93\nturtle.forward(150)    #\u753b\u7b14\u524d\u8fdb150\uff0c\u753b\u7b2c\u4e00\u6761\u8fb9\nturtle.right(120)      #\u5411\u53f3\u65cb\u8f6c120\u5ea6\nturtle.forward(150)    #\u753b\u7b2c\u4e8c\u6761\u8fb9\nturtle.right(120)      #\u7b2c\u4e8c\u6b21\u5411\u53f3\u65cb\u8f6c120\u5ea6\uff0c\nturtle.forward(150)    #\u753b\u7b2c\u4e09\u6761\u8fb9<\/textarea><\/pre><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki material-theme-lighter\" style=\"background-color: #FAFAFA\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #39ADB5; font-style: italic\">import<\/span><span style=\"color: #90A4AE\"> turtle          <\/span><span style=\"color: #90A4AE; font-style: italic\">#\u4f7f\u7528import\u8bed\u53e5\u5bfc\u5165turtle\u7ed8\u56fe\u5e93<\/span><\/span>\n<span class=\"line\"><span style=\"color: #90A4AE\">turtle<\/span><span style=\"color: #39ADB5\">.<\/span><span style=\"color: #6182B8\">forward<\/span><span style=\"color: #39ADB5\">(<\/span><span style=\"color: #F76D47\">150<\/span><span style=\"color: #39ADB5\">)<\/span><span style=\"color: #90A4AE\">    <\/span><span style=\"color: #90A4AE; font-style: italic\">#\u753b\u7b14\u524d\u8fdb150\uff0c\u753b\u7b2c\u4e00\u6761\u8fb9<\/span><\/span>\n<span class=\"line\"><span style=\"color: #90A4AE\">turtle<\/span><span style=\"color: #39ADB5\">.<\/span><span style=\"color: #6182B8\">right<\/span><span style=\"color: #39ADB5\">(<\/span><span style=\"color: #F76D47\">120<\/span><span style=\"color: #39ADB5\">)<\/span><span style=\"color: #90A4AE\">      <\/span><span style=\"color: #90A4AE; font-style: italic\">#\u5411\u53f3\u65cb\u8f6c120\u5ea6<\/span><\/span>\n<span class=\"line\"><span style=\"color: #90A4AE\">turtle<\/span><span style=\"color: #39ADB5\">.<\/span><span style=\"color: #6182B8\">forward<\/span><span style=\"color: #39ADB5\">(<\/span><span style=\"color: #F76D47\">150<\/span><span style=\"color: #39ADB5\">)<\/span><span style=\"color: #90A4AE\">    <\/span><span style=\"color: #90A4AE; font-style: italic\">#\u753b\u7b2c\u4e8c\u6761\u8fb9<\/span><\/span>\n<span class=\"line\"><span style=\"color: #90A4AE\">turtle<\/span><span style=\"color: #39ADB5\">.<\/span><span style=\"color: #6182B8\">right<\/span><span style=\"color: #39ADB5\">(<\/span><span style=\"color: #F76D47\">120<\/span><span style=\"color: #39ADB5\">)<\/span><span style=\"color: #90A4AE\">      <\/span><span style=\"color: #90A4AE; font-style: italic\">#\u7b2c\u4e8c\u6b21\u5411\u53f3\u65cb\u8f6c120\u5ea6\uff0c<\/span><\/span>\n<span class=\"line\"><span style=\"color: #90A4AE\">turtle<\/span><span style=\"color: #39ADB5\">.<\/span><span style=\"color: #6182B8\">forward<\/span><span style=\"color: #39ADB5\">(<\/span><span style=\"color: #F76D47\">150<\/span><span style=\"color: #39ADB5\">)<\/span><span style=\"color: #90A4AE\">    <\/span><span style=\"color: #90A4AE; font-style: italic\">#\u753b\u7b2c\u4e09\u6761\u8fb9<\/span><\/span><\/code><\/pre><\/div>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":69,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[],"class_list":["post-25","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-5"],"views":1410,"_links":{"self":[{"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/posts\/25","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/comments?post=25"}],"version-history":[{"count":1,"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/posts\/25\/revisions"}],"predecessor-version":[{"id":26,"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/posts\/25\/revisions\/26"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/media\/69"}],"wp:attachment":[{"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/media?parent=25"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/categories?post=25"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.pyteam.cn\/index.php\/wp-json\/wp\/v2\/tags?post=25"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}