{"blog_url":"https://inamori.hateblo.jp/","title":"Scala\u3067Project Euler\uff0823\uff09","author_url":"https://blog.hatena.ne.jp/inamori/","provider_url":"https://hatena.blog","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Finamori.hateblo.jp%2Fentry%2F20110610%2Fp1\" title=\"Scala\u3067Project Euler\uff0823\uff09 - inamori\u2019s diary\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","url":"https://inamori.hateblo.jp/entry/20110610/p1","image_url":null,"type":"rich","published":"2011-06-10 00:00:00","width":"100%","description":"Problem 12\u5f15\u304d\u7d9a\u304d\u7d04\u6570\u306e\u500b\u6570\u304c\u3042\u308b\u6570\u3088\u308a\u5927\u304d\u3044\u81ea\u7136\u6570\u3092\u6607\u9806\u306b\u5217\u6319\u3059\u308b\uff081\uff09\u3067Python\u3067\u66f8\u3044\u305f\u30b3\u30fc\u30c9\u3092Scala\u306b\u3057\u307e\u3059\u3002 Option \u6307\u6570\u306e\u7d44\u5408\u305b\u306b1\u52a0\u3048\u3066\u6b21\u306e\u6307\u6570\u306e\u7d44\u5408\u305b\u3059\u308bPython\u306e\u30b3\u30fc\u30c9\u306f\u6b21\u306e\u3088\u3046\u3067\u3057\u305f\u3002 for k in xrange(1, len(es0)): if es0[k-1] == es0[k] + 1: es2 = es0[:k] + (es0[k] + 1,) + es0[k+1:] pq.put((value(es2), es2)) break elif es0[k-1] > es0[k]: break else: if es0[-1] == 1: \u2026","version":"1.0","height":"190","blog_title":"inamori\u2019s diary","categories":["Scala"],"author_name":"inamori","provider_name":"Hatena Blog"}