ABCD pyramid not giving apt output

while I run my code I am unable to get ABCDDCBA and ABBA in the otput.

Hi @lipikarustagi, pls tell what is the expected pattern for any given n ??

ABCDE EDCBA in next line ABCD DCBA in next ABCCBA in next AB BA in next AA

RESOLVED the doubt, I had incremented twice