{"id":11714,"date":"2020-12-02T00:54:59","date_gmt":"2020-12-02T00:54:59","guid":{"rendered":"https:\/\/club.informatix.co.jp\/?p=11714"},"modified":"2024-10-31T02:56:12","modified_gmt":"2024-10-31T02:56:12","slug":"python%e3%81%a7%e6%95%b0%e5%ad%a6%e3%82%92%e5%ad%a6%e3%81%bc%e3%81%86%ef%bc%81%e6%a1%9c%e4%ba%95%e9%80%b2%e3%81%aepython%ef%bc%8bmath%e6%95%99%e5%ae%a4%e3%80%80%e7%ac%ac3%e5%9b%9e","status":"publish","type":"post","link":"https:\/\/club.informatix.co.jp\/?p=11714","title":{"rendered":"\u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u3092\u8868\u793a\u3059\u308b\u30b3\u30fc\u30c9\u3092\u5165\u529b\uff5cPython\u3067\u6570\u5b66\u3092\u5b66\u307c\u3046\uff01 \u7b2c3\u56de"},"content":{"rendered":"<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter wp-image-11732\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-11.jpg\" alt=\"\" width=\"700\" height=\"405\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-11.jpg 1280w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-11-300x173.jpg 300w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-11-1024x592.jpg 1024w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-11-768x444.jpg 768w\" sizes=\"(max-width: 700px) 100vw, 700px\" \/><\/span><\/p>\n<p style=\"text-align: center;\"><a href=\"https:\/\/www.python.org\" target=\"_blank\" rel=\"noopener noreferrer\">Python\u672c\u5bb6\u306e\u30db\u30fc\u30e0\u30da\u30fc\u30b8<\/a><\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">\u76ee\u6b21<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-69e489dd0f98d\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-69e489dd0f98d\" checked aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/club.informatix.co.jp\/?p=11714\/#%E3%83%95%E3%82%A3%E3%83%9C%E3%83%8A%E3%83%83%E3%83%81%E6%95%B0%E3%82%92%E8%A1%A8%E7%A4%BA%E3%81%99%E3%82%8B%E3%82%B3%E3%83%BC%E3%83%89\" >\u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u3092\u8868\u793a\u3059\u308b\u30b3\u30fc\u30c9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/club.informatix.co.jp\/?p=11714\/#Python%E3%81%A7%E3%81%AF%E3%82%A4%E3%83%B3%E3%83%87%E3%83%B3%E3%83%88%EF%BC%88%E8%A1%8C%E9%A0%AD%E7%A9%BA%E7%99%BD%EF%BC%89%E3%81%8C%E9%87%8D%E8%A6%81\" >Python\u3067\u306f\u30a4\u30f3\u30c7\u30f3\u30c8\uff08\u884c\u982d\u7a7a\u767d\uff09\u304c\u91cd\u8981<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/club.informatix.co.jp\/?p=11714\/#%E3%82%A4%E3%83%B3%E3%83%87%E3%83%B3%E3%83%88%E3%81%AB%E3%81%AF%E3%82%B3%E3%83%AD%E3%83%B3%E3%80%8C_%E3%80%8D%E3%81%8C%E3%82%BB%E3%83%83%E3%83%88\" >\u30a4\u30f3\u30c7\u30f3\u30c8\u306b\u306f\u30b3\u30ed\u30f3\u300c:\u300d\u304c\u30bb\u30c3\u30c8<\/a><\/li><\/ul><\/nav><\/div>\n\n<h2><span class=\"ez-toc-section\" id=\"%E3%83%95%E3%82%A3%E3%83%9C%E3%83%8A%E3%83%83%E3%83%81%E6%95%B0%E3%82%92%E8%A1%A8%E7%A4%BA%E3%81%99%E3%82%8B%E3%82%B3%E3%83%BC%E3%83%89\"><\/span>\u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u3092\u8868\u793a\u3059\u308b\u30b3\u30fc\u30c9<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><a href=\"https:\/\/club.informatix.co.jp\/?p=1934\" target=\"_blank\" rel=\"noopener\">\u7b2c1\u56de<\/a>\u3067\u3082\u7d39\u4ecb\u3057\u307e\u3057\u305f\u304c\u3001\u4eca\u5ea6\u306f\u305d\u306e\u30b3\u30fc\u30c9\u3092\u5165\u529b\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002\u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u3092\u8868\u793a\u3059\u308b\u30b3\u30fc\u30c9\u3067\u3059\u3002<\/p>\n<p>&gt;&gt;&gt; def fib(n):<br \/>\n&gt;&gt;&gt;\u00a0\u00a0\u00a0\u00a0 a, b = 0, 1<br \/>\n&gt;&gt;&gt;\u00a0\u00a0\u00a0\u00a0 while a &lt; n:<br \/>\n&gt;&gt;&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 print(a, end=&#8217; &#8216;)<br \/>\n&gt;&gt;&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 a, b = b, a+b<br \/>\n&gt;&gt;&gt;\u00a0\u00a0\u00a0\u00a0 print()<br \/>\n&gt;&gt;&gt; fib(1000)<br \/>\n0 1 1 2 3 5 8 13 21 34 55 89 144 233 377 610 987<\/p>\n<p>\u3053\u308c\u3092\u524d\u56de\u7d39\u4ecb\u3057\u305f\u30b0\u30fc\u30b0\u30ebColaboratory\u3067\u5b9f\u884c\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u30021\u884c\u305a\u3064\u5165\u529b\u3057\u307e\u3059\u3002\u30b3\u30fc\u30c9\u3092\u5165\u529b\u3057\u7d42\u308f\u3063\u305f\u3089\u30ea\u30bf\u30fc\u30f3\u3057\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11724\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-1.jpg\" alt=\"\" width=\"701\" height=\"261\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-1.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-1-300x112.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u3059\u308b\u3068\u3001\u6b21\u306e\u3088\u3046\u306b\u5de6\u7aef\u306b\u30b9\u30da\u30fc\u30b9\uff08\u30a4\u30f3\u30c7\u30f3\u30c8\uff09\u304c\u81ea\u52d5\u7684\u306b\u633f\u5165\u3055\u308c\u3066\u6b21\u306e\u884c\u306b\u30ab\u30fc\u30bd\u30eb\u304c\u73fe\u308c\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11725\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-2.jpg\" alt=\"\" width=\"701\" height=\"261\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-2.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-2-300x112.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>2\u884c\u76ee\u306e\u30b3\u30fc\u30c9\u300ca, b = 0, 1\u300d\uff0b\u30ea\u30bf\u30fc\u30f3\u3057\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11726\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-3.jpg\" alt=\"\" width=\"701\" height=\"261\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-3.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-3-300x112.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u30a4\u30f3\u30c7\u30f3\u30c8\u3055\u308c\u305f\u3068\u3053\u308d\u3067\u6539\u884c\u3055\u308c\u307e\u3059\u30023\u884c\u76ee\u306e\u30b3\u30fc\u30c9\u300cwhile a &lt; n:\u300d\uff0b\u30ea\u30bf\u30fc\u30f3\u3057\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11727\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-4.jpg\" alt=\"\" width=\"701\" height=\"261\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-4.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-4-300x112.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u3059\u308b\u3068\u518d\u3073\u81ea\u52d5\u30a4\u30f3\u30c7\u30f3\u30c8\u3055\u308c\u3066\u6539\u884c\u3057\u307e\u3059\u3002\u300cprint(a, end=&#8217; &#8216;)\u300d\uff0b\u30ea\u30bf\u30fc\u30f3\u3057\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11728\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-5.jpg\" alt=\"\" width=\"701\" height=\"318\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-5.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-5-300x136.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u30a4\u30f3\u30c7\u30f3\u30c8\u3055\u308c\u305a\u306b\u6539\u884c\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u3088\u3046\u306bColaboratory\u306f\u30b3\u30fc\u30c9\u3092\u8b58\u5225\u3057\u3066\u30a4\u30f3\u30c7\u30f3\u30c8\u3059\u308b\u304b\u3057\u306a\u3044\u304b\u3092\u5224\u65ad\u3057\u307e\u3059\u3002<\/p>\n<p>\u7d9a\u3051\u3066\u300ca, b = b, a+b\u300d\uff0b\u30ea\u30bf\u30fc\u30f3\u3057\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11729\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-6.jpg\" alt=\"\" width=\"701\" height=\"362\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-6.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-6-300x155.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u4e0a\u306e\u884c\u3068\u540c\u3058\u3068\u3053\u308d\u3067\u6539\u884c\u3055\u308c\u307e\u3057\u305f\u3002\u3053\u3053\u3067\u300c\u30c7\u30ea\u30fc\u30c8\u300d\u3057\u30661\u3064\u5206\u306e\u30a4\u30f3\u30c7\u30f3\u30c8\u3092\u524a\u9664\u3057\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11730\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-7.jpg\" alt=\"\" width=\"701\" height=\"362\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-7.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-7-300x155.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u300cprint()\u300d\uff0b\u30ea\u30bf\u30fc\u30f3\u3057\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11721\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-8.jpg\" alt=\"\" width=\"701\" height=\"362\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-8.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-8-300x155.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u3053\u308c\u3067def\u6587\u304c\u7d42\u308f\u308a\u306a\u306e\u3067\u300c\u30c7\u30ea\u30fc\u30c8\u300d\u3057\u3066\u30a4\u30f3\u30c7\u30f3\u30c8\u3092\u524a\u9664\u3057\u3001\u6700\u5f8c\u306e\u300cfib(1000)\u300d\u3092\u5165\u529b\u3057\u307e\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11722\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-9.jpg\" alt=\"\" width=\"701\" height=\"362\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-9.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-9-300x155.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u3053\u308c\u3067\u3059\u3079\u3066\u306e\u30b3\u30fc\u30c9\u306e\u5165\u529b\u304c\u7d42\u308f\u308a\u3067\u3059\u3002\u5b9f\u884c\u3055\u305b\u3066\u307f\u307e\u3059\u3002<\/p>\n<p>\u30bb\u30eb\u5de6\u4e0a\u306e\u53f3\u5411\u304d\u77e2\u5370\u30dc\u30bf\u30f3\u3092\u30af\u30ea\u30c3\u30af\u3059\u308b\u3068\u30bb\u30eb\u5185\u306e\u30b3\u30fc\u30c9\u304c\u5b9f\u884c\u3055\u308c\u307e\u3059\u3002<\/p>\n<p>\u6163\u308c\u3066\u304f\u308b\u3068\u30b7\u30e7\u30fc\u30c8\u30ab\u30c3\u30c8\u30ad\u30fc\u300c\u30b7\u30d5\u30c8\uff0b\u30ea\u30bf\u30fc\u30f3\u300d\u300c\u30b3\u30de\u30f3\u30c9\uff0b\u30ea\u30bf\u30fc\u30f3\u300d\u300c\u30b3\u30f3\u30c8\u30ed\u30fc\u30eb\uff0b\u30ea\u30bf\u30fc\u30f3\u300d\u3092\u4f7f\u3046\u3068\u4fbf\u5229\u3067\u3059\u3002<\/p>\n<p><span class=\"photoline\"><img decoding=\"async\" class=\"aligncenter size-full wp-image-11723\" src=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-10.jpg\" alt=\"\" width=\"701\" height=\"395\" srcset=\"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-10.jpg 701w, https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-10-300x169.jpg 300w\" sizes=\"(max-width: 701px) 100vw, 701px\" \/><\/span><\/p>\n<p>\u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u304c\u51fa\u529b\u3055\u308c\u307e\u3059\u3002\u95a2\u6570fib(n)\u306f\u300cn\u3088\u308a\u5c0f\u3055\u3044\u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u3092\u8868\u793a\u3059\u308b\u300d\u3068\u3044\u3046\u5185\u5bb9\u3067\u3042\u308b\u3053\u3068\u304c\u5206\u304b\u308a\u307e\u3059\u3002<\/p>\n<h2><span class=\"ez-toc-section\" id=\"Python%E3%81%A7%E3%81%AF%E3%82%A4%E3%83%B3%E3%83%87%E3%83%B3%E3%83%88%EF%BC%88%E8%A1%8C%E9%A0%AD%E7%A9%BA%E7%99%BD%EF%BC%89%E3%81%8C%E9%87%8D%E8%A6%81\"><\/span>Python\u3067\u306f\u30a4\u30f3\u30c7\u30f3\u30c8\uff08\u884c\u982d\u7a7a\u767d\uff09\u304c\u91cd\u8981<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>\u3053\u306e\u77ed\u3044\u30b3\u30fc\u30c9\u306e\u306a\u304b\u306bPython\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u306e\u30dd\u30a4\u30f3\u30c8\u3092\u898b\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002\u305d\u308c\u304c\u30a4\u30f3\u30c7\u30f3\u30c8\uff08\u884c\u982d\u7a7a\u767d\uff09\u3067\u3059\u3002<\/p>\n<p>\u3053\u308c\u307e\u3067\u306e\u591a\u304f\u306e\u30d7\u30ed\u30b0\u30e9\u30e0\u8a00\u8a9e\u306f\u7bc4\u56f2\u3092\u6307\u5b9a\u3059\u308b\u306e\u306b{}\u3092\u7528\u3044\u307e\u3059\u304c\u3001Python\u306f\u9055\u3044\u307e\u3059\u3002{}\u306e\u4ee3\u308f\u308a\u306b\u30a4\u30f3\u30c7\u30f3\u30c8\uff08\u884c\u982d\u7a7a\u767d\uff09\u3092\u7528\u3044\u307e\u3059\u3002{}\u306b\u6163\u308c\u305f\u4eba\u306f\u9055\u548c\u611f\u3092\u611f\u3058\u308b\u304b\u3082\u3057\u308c\u307e\u305b\u3093\u3002<\/p>\n<p>\u3057\u304b\u3057\u3001\u4f7f\u3044\u9032\u3081\u3066\u3044\u304f\u3046\u3061\u306b\u305d\u306e\u826f\u3055\u304c\u5206\u304b\u3063\u3066\u304d\u307e\u3059\u3002\u30b3\u30fc\u30c9\u306e\u8996\u8a8d\u6027\u3067\u3059\u3002\u3069\u3053\u304b\u3089\u3069\u3053\u307e\u3067\u304c\u30d6\u30ed\u30c3\u30af\u306a\u306e\u304b\u304c\u4e00\u76ee\u3067\u5206\u304b\u308a\u307e\u3059\u3002\u3053\u306e\u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u306e\u30b3\u30fc\u30c9\u3067\u306f\u30d6\u30ed\u30c3\u30af\u304c<span style=\"font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;\">2\u3064<\/span>\u3042\u308a\u307e\u3059\u3002<\/p>\n<p>\u6700\u521d\u304cdef\u6587\u3067\u3059\u3002\u95a2\u6570\u3092\u5b9a\u7fa9\uff08definition\uff09\u3059\u308b\u95a2\u6570\u3067\u3059\u3002\u6700\u5f8c\u306e7\u884c\u76ee\u3067\u30a4\u30f3\u30c7\u30f3\u30c8\u304c\u306a\u304f\u306a\u3063\u3066\u3044\u308b\u3053\u3068\u304b\u3089\u3001def\u6587\u306e\u30d6\u30ed\u30c3\u30af\u304c6\u884c\u76ee\u307e\u3067\u3068\u5206\u304b\u308a\u307e\u3059\u3002<\/p>\n<p>2\u756a\u76ee\u304cwhile\u6587\u3067\u3059\u3002\u6761\u4ef6\u5206\u5c90\u3059\u308b\u95a2\u6570\u3067\u3059\u30026\u884c\u76ee\u306eprint\u6587\u3067\u30a4\u30f3\u30c7\u30f3\u30c8\u304c\u306a\u304f\u306a\u3063\u3066\u3044\u308b\u306e\u30673\u884c\u6587\u304c\u30d6\u30ed\u30c3\u30af\u3060\u3068\u5206\u304b\u308a\u307e\u3059\u3002<\/p>\n<h2><span class=\"ez-toc-section\" id=\"%E3%82%A4%E3%83%B3%E3%83%87%E3%83%B3%E3%83%88%E3%81%AB%E3%81%AF%E3%82%B3%E3%83%AD%E3%83%B3%E3%80%8C_%E3%80%8D%E3%81%8C%E3%82%BB%E3%83%83%E3%83%88\"><\/span>\u30a4\u30f3\u30c7\u30f3\u30c8\u306b\u306f\u30b3\u30ed\u30f3\u300c:\u300d\u304c\u30bb\u30c3\u30c8<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>\u300cdef fib(n):\u300d\u300cwhile a &lt; n:\u300d\u304b\u3089\u5206\u304b\u308b\u3088\u3046\u306b\u3001\u6700\u5f8c\u306b\u30b3\u30ed\u30f3\u300c:\u300d\u3092\u4ed8\u3051\u308b\u306e\u304cPython\u306e\u4f5c\u6cd5\u3067\u3059\u3002Colaboratory\u304c\u81ea\u52d5\u30a4\u30f3\u30c7\u30f3\u30c8\u3092\u3057\u3066\u304f\u308c\u308b\u306e\u306f\u300c:\u300d\u306e\u3042\u308b\u306a\u3057\u3092\u5224\u5b9a\u3057\u3066\u3044\u308b\u3068\u601d\u308f\u308c\u307e\u3059\u3002<\/p>\n<p>\u3061\u306a\u307f\u306b\u3001\u666e\u901a\u306e\u30c6\u30ad\u30b9\u30c8\u30a8\u30c7\u30a3\u30bf\u30fc\u3067\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u3059\u308b\u969b\u306b\u306f\u81ea\u52d5\u30a4\u30f3\u30c7\u30f3\u30c8\u3057\u3066\u304f\u308c\u307e\u305b\u3093\u3002\u624b\u52d5\u3067\u30a4\u30f3\u30c7\u30f3\u30c8\u3059\u308b\u5fc5\u8981\u304c\u3042\u308a\u307e\u3059\u3002\u3053\u306e\u3053\u3068\u306f\u307e\u305f\u5225\u306e\u6a5f\u4f1a\u306b\u3068\u308a\u3042\u3052\u307e\u3059\u3002<\/p>\n<p>\u3053\u306e\u30b3\u30fc\u30c9\u3092\u81ea\u5206\u306a\u308a\u306b\u5909\u66f4\u3057\u3066\u904a\u3093\u3067\u307f\u307e\u3057\u3087\u3046\u3002<\/p>\n<p><a href=\"https:\/\/club.informatix.co.jp\/?p=12181\" target=\"_blank\" rel=\"noopener\">\u6b21\u56de<\/a>\u306f\u300c\u7d20\u6570\u5224\u5b9a\u30d7\u30ed\u30b0\u30e9\u30e0\u300d\u3092\u30b3\u30fc\u30c7\u30a3\u30f3\u30b0\u3057\u3066\u307f\u307e\u3059\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Python\u672c\u5bb6\u306e\u30db\u30fc\u30e0\u30da\u30fc\u30b8 \u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u3092\u8868\u793a\u3059\u308b\u30b3\u30fc\u30c9 \u7b2c1\u56de\u3067\u3082\u7d39\u4ecb\u3057\u307e\u3057\u305f\u304c\u3001\u4eca\u5ea6\u306f\u305d\u306e\u30b3\u30fc\u30c9\u3092\u5165\u529b\u3057\u3066\u307f\u307e\u3057\u3087\u3046\u3002\u30d5\u30a3\u30dc\u30ca\u30c3\u30c1\u6570\u3092\u8868\u793a\u3059\u308b\u30b3\u30fc\u30c9\u3067\u3059\u3002 &gt;&gt;&gt; def  &#8230; <\/p>\n","protected":false},"author":4,"featured_media":11732,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,464,526],"tags":[65],"class_list":["post-11714","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-4","category-hito-star-mathmatics","category-526","tag-python"],"jetpack_featured_media_url":"https:\/\/club.informatix.co.jp\/wp-content\/uploads\/2020\/12\/20201201-11.jpg","_links":{"self":[{"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=\/wp\/v2\/posts\/11714","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=11714"}],"version-history":[{"count":19,"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=\/wp\/v2\/posts\/11714\/revisions"}],"predecessor-version":[{"id":20729,"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=\/wp\/v2\/posts\/11714\/revisions\/20729"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=\/wp\/v2\/media\/11732"}],"wp:attachment":[{"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=11714"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=11714"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/club.informatix.co.jp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=11714"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}