Getting one test case wrong

plz help me find out y test case is wrng
code : https://ide.codingblocks.com/s/121419

if you give input
3
bbb
it will give 6 according to your code


use this code
if you suck anywhere feel free to ask us