title: Issue regarding wrong output with a HackerRank statement on anagrams
body: <p>For problem statement, please see <a href="https://www.hackerrank.com/challenges/ctci-making-anagrams/problem" rel="nofollow noreferrer">this.</a>   </p>
  
  <p>(I have omitted libraries.)</p>
  
  <p>My code works fine (when online judge tests the code) except for this case:</p>
  
  <p>aaaaaaaaaaaaaaaaaaaaaaaaaaaaa
  bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb</p>
  
  <p>I would love to know why output it expects to be 104 when intersection is zero?</p>
  
  <pre><code>std::string string_intersection;
  
  int number_needed(string a, string b) {
  
  int y = a.length();
  int z = b.length();
  
  sort(a.begin(), a.end());
  sort(b.begin(), b.end());
  
  std::set_intersection(a.begin(), a.end(), b.begin(), b.end(), std::back_inserter(string_intersection));
  
  int num, x = string_intersection.length();
  
  if(x==0)
      num = 0;
  
  else
  
  num = y + z - 2*x;
  
  return num;
  
  
  }
  
      int main(){
      string a;
      cin &gt;&gt; a;
      string b;
      cin &gt;&gt; b;
      cout &lt;&lt; number_needed(a, b) &lt;&lt; endl;
      return 0;
  }
  </code></pre>