{"description":"[1, 2, 3].each_with_object(Array.new) do |i, memo| memo += [i, i * 2] end # => [ ] \u3042\u308c\uff01\uff1f [[1, 2], [2, 4], [3, 6]] \u306b\u306a\u308b\u3068\u601d\u3063\u305f\u306e\u306b\uff01\uff1f Ruby - Enumerable.each_with_object \u306e\u4f7f\u3044\u9053 - Qiitaqiita.com Ruby - inject\u3068each_with_object\u3063\u3066\u4f55\u304c\u9055\u3046\u306e\u3055\uff1f - Qiitaqiita.com \u3082\u3046\u3055\u3093\u3056\u3093\u65e2\u51fa\u3067\u3059\u306d\uff01 Enumerable#each_with_object \u306f\u5f15\u6570\u306b\u5bfe\u3057\u3066\u7834\u58ca\u7684\u306a\u5909\u66f4\u3092\u52a0\u3048\u306a\u3051\u308c\u3070\u2026","image_url":null,"author_name":"magicalhat","title":" Enumerable#each_with_object \u3067\u30cf\u30de\u3063\u305f","blog_title":"\u306f\u3061\u3085\u306b\u3063\u304d","author_url":"https://blog.hatena.ne.jp/magicalhat/","version":"1.0","html":"<iframe src=\"https://hatenablog-parts.com/embed?url=https%3A%2F%2Fhatyuki.hatenablog.jp%2Fentry%2F2015%2F07%2F09%2F162009\" title=\" Enumerable#each_with_object \u3067\u30cf\u30de\u3063\u305f - \u306f\u3061\u3085\u306b\u3063\u304d\" class=\"embed-card embed-blogcard\" scrolling=\"no\" frameborder=\"0\" style=\"display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;\"></iframe>","width":"100%","url":"https://hatyuki.hatenablog.jp/entry/2015/07/09/162009","provider_url":"https://hatena.blog","blog_url":"https://hatyuki.hatenablog.jp/","categories":["Ruby"],"provider_name":"Hatena Blog","height":"190","type":"rich","published":"2015-07-09 16:20:09"}