title: Use include? instead of a tracker
body: <pre><code>def add app
    @has_app[app] = true
    @apps &lt;&lt; app
  end
  </code></pre>
  
  <p>In <a href="http://github.com/rack/rack/blob/3d000c5690715be1f1424ce70b08a702c8528d03/lib/rack/cascade.rb" rel="nofollow noreferrer">the code above</a>, instead of using </p>
  
  <pre><code>@has_app[app] = true 
  </code></pre>
  
  <p>to keep track of the presence of 'app', couldn't we also say:</p>
  
  <pre><code>@apps.include? (app)
  </code></pre>
  
  <p>and do away with <code>@has_app</code>? </p>
  
  <p>I'm trying to understand why this separate variable is needed here at all (?).</p>