title: how can we count or compare strings?
body: <p>i want it to read 1 string at a time and count how many time a string appears after the comma like if A appear there is count += 1  and if B appears there a seperate count+= 1   and then do the same thing to another string and if it appear twices more than the first string than save it</p>
  
  <p>Ex: </p>
  
  <pre><code>string num1 = "A, B , C, AB, AC"
  string num2 = "A, B, C , AB, A, C, AC, AB"
  istringstream uc(num2);
  string num3
  while(getline(uc,num3,',')) //get part of the string after you see ','
  {
  
  
  }
  </code></pre>
  
  <p>result: since they appear twice </p>
  
  <pre><code>C, AB , A
  </code></pre>