Comments

:( do you know any ways to avoid it

Plus my c++ code is what i submitted during the contest and it had the same time complexity as the editorial code.