Send your feedback or ask for help here!
Is ‘A’ and ‘a’ regarded as “common”? It is undefined.
There was the same question in contribution, without answer.
Yes, ‘a’ and ‘A’ are indeed the same letter. Surely you knew
Edit: Joking aside, I clarified it in the text.
Surely you knew it should have been written.
Maybe it is a language thing? In English it is very clear as originally written… they are the same letter, but different characters.
If people ask for it, here and in the contribution page, it’s because it’s not clear.
It’s not because it’s clear for you that it’s clear for anybody else. You don’t publish a puzzle only for you.
Moreover, I don’t know if a common repeated letter is counted only once or not. It’s not in the statement.
One last thing: it does not seem to me that it’s a medium puzzle.
Maybe you kept your tab open and didn’t see it but the statement has been updated yesterday evening about repeating letters and now it’s fine.
I think it would be medium without a doubt with a slightly smaller n but with the current n I couldn’t complete it in python with a basic algo, I had to use additionnal tricks to pass testcase 5 (sorting and early breaks).
So it makes it medium++ for “slow” languages.
I solve it with python3 and c++ with the same basic approach, without sorting or early breaks.
But I agree, it’s between medium and hard problem.
I you don’t mind sharing your solution - not here ofc but in the dedicated section, I’ll take a look at it.
Edit : I found a faster solution than my previous one that uses set intersection, it might be what you were thinking of. It doesn’t require sorting and early break indeed and is quite short.
Done, I used only one simple recursive function
Nice! It is good to see people mostly liked this puzzle, except for the two people who really really hated it
It’s not a question of hate but a question of clarity.