title: How to use for each group in XSL
body: <p>im still learning <code>for-each-group</code> what is the best way of grouping something like this using XSL?(by country) i'm trying to use XSL to convert this XML to another XML. </p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;Person&gt;
      &lt;Student&gt;
          &lt;Info Country="England" Name="Dan" Age="20" Class="C" /&gt;
      &lt;/Student&gt;
      &lt;Student&gt;
          &lt;Info Country="England" Name="Dan" Age="20" Class="B" /&gt;
  
      &lt;/Student&gt;
      &lt;Student&gt;
          &lt;Info Country="England" Name="Sam" Age="20" Class="A" /&gt;
      &lt;/Student&gt;
  
      &lt;Student&gt;
         &lt;Info Country="Australia" Name="David" Age="22" Class="D" /&gt;
      &lt;/Student&gt;
      &lt;Student&gt;
          &lt;Info Country="Australia" Name="David" Age="22" Class="A" /&gt;
      &lt;/Student&gt;
  
  &lt;/Person&gt;
  </code></pre>