Maximum Circles Code

Here is the code of the question:- https://ide.codingblocks.com/s/475097, please specify what is the error as two test cases are not passing.

hello @Sakshi2004
first sort all the cirlces based on rightmost most point( which is r+c)

btw what u are trying here->

all u need to check is right most corrdinate of last picked circle <= left most coordinate of current circle (more like activity selection problem)

I got your approach, but still we can do this also just need to sort the vector according to center of circles? Then what is wrong in this?

…

centre of circle is not sufficient to put all circle in a proper sequence
becuase circle radius also play vital role to place circle in proper order.