mengli / leetcode

leetcode
190 stars 121 forks source link

Best Time to Buy and Sell Stock III #1

Closed xiongjunliang closed 10 years ago

xiongjunliang commented 11 years ago

蒙拿,你这题的code大数据超时呀,O(N^2)的算法复杂度要超时的。 需要O(N)的算法才能过的。 https://github.com/xiongjunliang/leetcode/blob/master/stock3/stock3.cpp

mengli commented 11 years ago

是的,还有几个题目也是大数据没有过,等我搞完托福抽时间搞一下。

mengli commented 10 years ago

Hi xiongjunliang,

I have fixed the time out bug of Best Time to Buy and Sell Stock III. Thank you for your information!

Meng

xiongjunliang commented 10 years ago

Good Job!