<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>sucrose</author_name>
  <author_url>https://blog.hatena.ne.jp/sucrose/</author_url>
  <blog_title>唯物是真 @Scaled_Wurm</blog_title>
  <blog_url>https://sucrose.hatenablog.com/</blog_url>
  <categories>
    <anon>euler</anon>
    <anon>python</anon>
  </categories>
  <description>Problem 61 - Project Euler 3,4,5,6,7,8角数を計算して、それぞれのn角数から1つずつを使って、最初の2桁と最後の2桁が一致していくようなループ(3つだけの場合の例、8128, 2882, 8281)を見つける。2桁が限定される時点でかなり制限されるので、あらかじめn角数を計算して先頭か末尾の2桁を保持しておいて、深さ優先探索っぽくやればいい。 import copy def triangle(n): return n * (n + 1) / 2 def square(n): return n * n def pentagonal(n): return n *…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fsucrose.hatenablog.com%2Fentry%2F2012%2F08%2F25%2F220117&quot; title=&quot;Project Euler Problem 61 - 唯物是真 @Scaled_Wurm&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2012-08-25 22:01:17</published>
  <title>Project Euler Problem 61</title>
  <type>rich</type>
  <url>https://sucrose.hatenablog.com/entry/2012/08/25/220117</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
