Unique String Question

Sir i have used this approach like store the frequency of characters of all the strings and counted the count>=1
For eg store frequency of ab cd ab where count of a=2,b=2c=1,d=1 hence resulting unique string should contain these 4 hence max length=4; Sir can you please explain what is wrong in this approach;

Only my two test cases passed.

hello @vdeepu028
no this approach will not work for example.
[aa,bb]
u will print 2 but answer is 0.

Thanks… For quick reply.