Error showing up for big data

sir please check my solution

@anupanu23 Please save your code on ide.codingblocks.com and share its link.

if i dont take dynammic array two test cases are passsed