[algogeeks] Re: Zig-zag subsequence

2009-05-09 Thread Raghav Kumar Gautam
Thanks > Vladimir > > Try dynamic programming. Complexity of the algorithm would be O(n^3). -Raghav Kumar Gautam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Algorithm Geeks" group. To post to thi

[algogeeks] Re: find k-th smallest element in the set of combined m+n elements

2009-05-07 Thread Raghav Kumar Gautam
s. Runtime: The algorithm preseted would actually take O(log k). But in general the complexity would be min of O(log(max(A_len+B_len))) and O(log k). - Raghav Kumar Gautam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Gro