title: How to count and rename duplicate rows in a DataTable
body: <p>I found plenty of stuff on deleting duplicates, but I couldn't find any guidance for the problem below anywhere...</p>
  
  <p>I'm looking for a way to rename any duplicate rows in a C# DataTable that I've imported to from a CSV. My data looks something like:</p>
  
  <pre class="lang-none prettyprint-override"><code>**Name**       **Item**                 **Quantity**
  ABC            Item_Name                     6
  ABC            Item_Name_2                   1
  DEF            Item_Name                     3
  GHI            Item_Name_2                   7
  ABC            Item_Name                     6
  ABC            Item_Name                     1
  JKL            Item_Name_3                   4
  ABC            Item_Name                     6
  ABC            Item_Name                     1
  JKL            Item_Name_3                   4
  </code></pre>
  
  <p>What I would like the data to look like, if a whole row (quantity included) appears more than once, is this:</p>
  
  <pre class="lang-none prettyprint-override"><code>**Name**          **Item**                 **Quantity**
  ABC            Item_Name                        6
  ABC            Item_Name_2                      1
  DEF            Item_Name                        3
  GHI            Item_Name_2                      7
  ABC (2)        Item_Name                        6
  ABC (2)        Item_Name_2                      1
  JKL            Item_Name_3                      4
  ABC (3)        Item_Name                        6
  ABC (3)        Item_Name_2                      1
  JKL (2)        Item_Name_3                      4
  </code></pre>
  
  <p>At present, I'm using a double "for loop" to determine which rows further down the table have the same data as the present row and rename them accordingly. Clearly, this has two issues:</p>
  
  <ol>
  <li><p>It's really slow with tables with a large number of rows, obviously</p></li>
  <li><p>All future rows whose name column was "ABC" now have a name column "ABC (2)", regardless of whether this is their first second or 98th occurrence (because, to be frank, my code sucks). </p></li>
  </ol>
  
  <p>Any help anyone can offer greatly appreciated :)</p>