title: Output of Iterable.sliding as Tuple
body: <p>The method <strong>sliding</strong> on collections returns a sliding window of given size in the form of <code>X[Iterable[A]]</code> with X being the type of the collection and A the element type. Often I need two or three elements and I prefer to have them named. One ugly workaround for <code>sliding(2)</code> is the following:</p>
  
  <pre><code>points.sliding(2).foreach{ twoPoints =&gt;
        val (p1,p2) = (twoPoints.head,twoPoints.last)
        //do something
  }
  </code></pre>
  
  <p>This sucks and only works for two elements. Also note that </p>
  
  <pre><code>(a,b) = (twoPoints(0),twoPoints(1))
  </code></pre>
  
  <p>doesn't work.</p>