{"version":"1.0","title":"Problem 6","url":"https://nitamago-archive.hatenablog.com/entry/20080907/1220797496","height":"190","categories":["ProjectEuler","C"],"blog_url":"https://nitamago-archive.hatenablog.com/","provider_name":"Hatena Blog","author_url":"https://blog.hatena.ne.jp/emergent/","published":"2008-09-07 23:24:56","type":"rich","description":"\u4eca\u56de\u306f\u7c21\u5358\u3060\u306a\u3002\u307e\u3060\u307e\u3060\u5e8f\u76e4\u3060\u304b\u3089\u304b\u3002 \u6700\u521d\u306e10\u500b\u306e\u81ea\u7136\u6570\u306b\u3064\u3044\u3066\u3001\u305d\u306e\u548c\u306e\u4e8c\u4e57\u3068\u3001\u4e8c\u4e57\u6570\u306e\u548c\u306f\u4ee5\u4e0b\u306e\u901a\u308a\u3002 1\u00b2 + 2\u00b2 + ... + 10\u00b2 = 385 (1 + 2 + ... + 10)\u00b2 = 3025 \u3053\u308c\u3089\u306e\u6570\u306e\u5dee\u306f 3025 - 385 = 2640 \u3068\u306a\u308b\u3002 \u540c\u69d8\u306b\u3057\u3066\u3001\u6700\u521d\u306e100\u500b\u306e\u81ea\u7136\u6570\u306b\u3064\u3044\u3066\u548c\u306e\u4e8c\u4e57\u3068\u4e8c\u4e57\u306e\u548c\u306e\u5dee\u3092\u6c42\u3081\u3088\u3002 Problem 6 - PukiWiki \u305d\u308c\u305e\u308c\u884c\u3046\u95a2\u6570\u3092\u4f5c\u6210\u3057\u3066\u5b9f\u884c\u3002 #include <stdio.h> #define NUM_MAX 100 int sumsq(int max) { int i, ret; ret = 0; fo\u2026","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fnitamago-archive.hatenablog.com%2Fentry%2F20080907%2F1220797496\" title=\"Problem 6 - \u306b\u305f\u307e\u3054\u307b\u3046\u308c\u3093\u8349\u30a2\u30fc\u30ab\u30a4\u30d6\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","provider_url":"https://hatena.blog","width":"100%","blog_title":"\u306b\u305f\u307e\u3054\u307b\u3046\u308c\u3093\u8349\u30a2\u30fc\u30ab\u30a4\u30d6","author_name":"emergent","image_url":null}