|
|
вернуться в форумDP in O(n^2) Послано tjj 11 авг 2006 15:21 For it is a convex polygon the best path won't self-cross, so a vertex Pi can only be connected to Pi-1 or Pi+1. Good Luck! Edited by author 11.08.2006 16:27 Re: DP in O(n^2) Послано tjj 11 авг 2006 16:27 Sorry, what I meant was Pi must be connected to Pi-1 or Pi+1 or both of them. Re: DP in O(n^2) Then why do you call it DP and O(N^2)? It'll be just O(N) - find shortest side and send the loop around ploygon excluding that side. Edited by author 12.08.2008 16:38 |
|
|