// You are given two strings s and t.

// String t is generated by random shuffling string s and then add one more letter at a random position.

// Return the letter that was added to t.

 

// Example 1:

// Input: s = "abcd", t = "abcde"
// Output: "e"
// Explanation: 'e' is the letter that was added.


#include<bits/stdc++.h>
using namespace std;

class Solution {
public:
    char findTheDifference(string s, string t) {
      unordered_map<char, int>h1;
        for(int i=0;i<s.length();i++)
        {
            h1[s[i]]++;
        }
         for(int i=0;i<t.length();i++)
        {
            h1[t[i]]++;
        }
        
        for(int i=0;i<t.length();i++)
        {
            if((h1[t[i]]&1)==1)
            {
                return t[i];
            }
        }
       return 'a';
        
    }
};