title: foreach loop in scala
body: <p>In scala foreach loop if I have list</p>
  
  <pre><code>val a = List("a","b","c","d")
  </code></pre>
  
  <p>I can print them without a pattern matching like this</p>
  
  <pre><code>a.foreach(c =&gt; println(c))
  </code></pre>
  
  <p>But, if I have a tuple like this</p>
  
  <pre><code>val v = Vector((1,9), (2,8), (3,7), (4,6), (5,5))
  </code></pre>
  
  <p>why should I have to use </p>
  
  <pre><code>v.foreach{ case(i,j) =&gt; println(i, j) }
  </code></pre>
  
  <ol>
  <li>a pattern matching case</li>
  <li>{ brackets</li>
  </ol>
  
  <p>Please explain what happens when the two foreach loops are executed.</p>