Cannot find whats wrong with the code

in question “Redundant Parentheses”, my code runs fine but still it got wrong testcases after submitting. please tell me whats wrong with the code.
my code: https://ide.codingblocks.com/s/108963

@zodiac hey Shantanu there is only one mistake in your code in the question given “Not Duplicates”. but you printing “Not Duplicate”