<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>tofucodes</author_name>
  <author_url>https://blog.hatena.ne.jp/tofucodes/</author_url>
  <blog_title>tofucodes diary</blog_title>
  <blog_url>https://tofucodes.hatenablog.jp/</blog_url>
  <categories>
    <anon>ruby</anon>
  </categories>
  <description>仕事で先人のRubyのコードを見てたらEnumeratorというクラスが出てきました。 初見だったのでググってドキュメントを見てみたがよく分かりませんでした。 特に「遅延評価」てところがパッときませんでした。 (1..Float::INFINITY).map{ |n| n * 2 }.first(5) =&gt; 無限リストをループするためfirstまで実行されず処理が終わらない (1..Float::INFINITY).first(5) =&gt; [1,2,3,4,5] これが遅延評価（どん！）。 どうでしょうか？分かりましたか？ 僕は上記ではよく分かりませんでしたが、Enumerator::Lazy…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftofucodes.hatenablog.jp%2Fentry%2F2015%2F12%2F10%2F232503&quot; title=&quot;RubyのEnumeratorが理解できたような気がした話 - tofucodes diary&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>2015-12-10 23:25:03</published>
  <title>RubyのEnumeratorが理解できたような気がした話</title>
  <type>rich</type>
  <url>https://tofucodes.hatenablog.jp/entry/2015/12/10/232503</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
