TESTCASE # 1 : correct (Time: 0 s)
TESTCASE # 2 : correct (Time: 0 s)
TESTCASE # 3 : wrong-answer (Time: 0 s)
TESTCASE # 4 : correct (Time: 0 s)
TESTCASE # 5 : wrong-answer (Time: 0 s)
Strings-Max Frequency Character
in ur code you are u are updating the value of it2->second but are printing the it2->first which gives wrong ans. to correct this take a char ch where you have to store the character whose counts is maximum. in the for loop of itr in the if case add a statement ch=itr->first and in cout statement use ch then all test case will pass.
In the for loop of itr in the if case add a statement ch=itr->first and in cout statement use ch
in the for loop of itr in the if case add a statement ch=itr->first is not working