Just a simple thought....I am assuming all points are unique....

Create a queue that is made to contain the points...

say points queue [1000];

for i:1 to n
  for j:i+1 to n
      Calculate d (distance between the two centers)
       if (d >= r0 + r1) keep them in two separate queues
       if(d< r0 + r1) ignore the point with smaller radius //as it
will overshadowed the bigger circle completely
        keep both of them in one single queue

Now calculate the area of the circles in those queues which have
single element...

those with more than one element..calculate the area using simple geometry...

Hope the above algo is clear...

On 7/19/11, SAMMM <somnath.nit...@gmail.com> wrote:
> See the input will be :-
>
> 6<---- No of circles
>
> x1 y1 R1
> x2 y2 R2
> x3 y3 R3
> x4 y4 R4
> x5 y5 R5
> x6 y6 R6
>
> Output:-
> Area occupied by the above circles (one line) 4 decimal points .
>
>
> On Jul 19, 9:01 pm, priyanka goel <priya888g...@gmail.com> wrote:
>> can u pl tell wat is dis x & y coordinate?
>> are dey centre coordinates or any point on circumference of circle..
>
> --
> You received this message because you are subscribed to the Google Groups
> "Algorithm Geeks" group.
> To post to this group, send email to algogeeks@googlegroups.com.
> To unsubscribe from this group, send email to
> algogeeks+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/algogeeks?hl=en.
>
>


-- 
*Piyush Sinha*
*IIIT, Allahabad*
*+91-7483122727*
* <https://www.facebook.com/profile.php?id=100000655377926> "NEVER SAY
NEVER"
*

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algogeeks@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to