4 cases failing

I checked using the condition if (s[i] == s[j] && i != j)
Here is my code : https://ide.codingblocks.com/s/151696

Please share your complete code so that i can figure out what might be wrong in your code.

Till then you can have a look to my code here.

Here is my code

I have modified your code. Please have a look.

Its still giving WA on 1st 4 cases

I have modified your code. Please do read the comments.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.