<p>You are given two strings of the same length <code>s</code> and <code>t</code>. In one step you can choose <strong>any character</strong> of <code>t</code> and replace it with <strong>another character</strong>.</p>

<p>Return <em>the minimum number of steps</em> to make <code>t</code> an anagram of <code>s</code>.</p>

<p>An <strong>Anagram</strong> of a string is a string that contains the same characters with a different (or the same) ordering.</p>

<p>&nbsp;</p>
<p><strong class="example">Example 1:</strong></p>

<pre>
<strong>Input:</strong> s = &quot;bab&quot;, t = &quot;aba&quot;
<strong>Output:</strong> 1
<strong>Explanation:</strong> Replace the first &#39;a&#39; in t with b, t = &quot;bba&quot; which is anagram of s.
</pre>

<p><strong class="example">Example 2:</strong></p>

<pre>
<strong>Input:</strong> s = &quot;leetcode&quot;, t = &quot;practice&quot;
<strong>Output:</strong> 5
<strong>Explanation:</strong> Replace &#39;p&#39;, &#39;r&#39;, &#39;a&#39;, &#39;i&#39; and &#39;c&#39; from t with proper characters to make t anagram of s.
</pre>

<p><strong class="example">Example 3:</strong></p>

<pre>
<strong>Input:</strong> s = &quot;anagram&quot;, t = &quot;mangaar&quot;
<strong>Output:</strong> 0
<strong>Explanation:</strong> &quot;anagram&quot; and &quot;mangaar&quot; are anagrams. 
</pre>

<p>&nbsp;</p>
<p><strong>Constraints:</strong></p>

<ul>
	<li><code>1 &lt;= s.length &lt;= 5 * 10<sup>4</sup></code></li>
	<li><code>s.length == t.length</code></li>
	<li><code>s</code> and <code>t</code> consist of lowercase English letters only.</li>
</ul>

class Solution:
    def minSteps(self, s: str, t: str) -> int:
        shash = {}
        thash = {}

        for x in s:
            if x not in shash:
                shash[x]=1
            else:
                shash[x]+=1
        for x in t:
            if x not in thash:
                thash[x]=1
            else:
                thash[x]+=1
        print(shash)
        print(thash)
        count = 0 
        for x in s:
            if x in thash and thash[x]>0:
                thash[x]-=1
            else:
                count +=1
        return count 
















        # find the count of characters in t which are not presnt in s 
        # calculate frequency of each character 
        # focus on positive values - 
        # shash = {}
        # thash = {}

        # for x in s:
        #     if x not in shash:
        #         shash[x]=1
        #     else:
        #         shash[x]+=1
        # for x in t:
        #     if x not in thash:
        #         thash[x]=1
        #     else:
        #         thash[x]+=1
        
        # count = 0 

        # # for key,val in shash.items():
        # #     # for each char - checks if it in the thash map - if yes and it is equal then add that to the count 
        # #     if key in thash:

        # #         if val == thash[key]:
        # #             count +=val 
        # #         else:
        # #             # if not present then add the min of the shash and thash 
        # #             count += min(val,thash[key])
        # #         # if it is not in thash - do not add it 
        # # # count is keeping track of which elements are the same - then in the end return the difference 
        # # return len(s)-count 

        # for x in shash.keys():
        #     if x in thash:
        #      # if it is thash - then just add the absolute value of the difference 
        #         # if there is more is shash we need to add it - 
        #         # we dont care about values in the thash because we are adding shash values so just need to make sure we add the difference between the shash and thash values 
        #         if thash[x]<shash[x]:
        #             count+=abs(thash[x]-shash[x])
       
        #     else:
        #         # else just add the amount to count 
        #         count+=shash[x]



        # return count 
        
17000