codolove's blog

By codolove, 11 years ago, In English

I was trying to apply the divide and conquer algorithm for closest pair of points on this problem. I have been getting wrong answer many times. My solution is here. I read this algorith from this site.

  • Vote: I like it
  • +6
  • Vote: I do not like it

| Write comment?
»
11 years ago, hide # |
 
Vote: I like it +3 Vote: I do not like it

In 23-rd line you multiply ints up to 106. It will cause overflow. And be careful about number of digits in output.