2014年12月1日

[leetcode] Best Time to Buy and Sell Stock Ⅰ Ⅱ Ⅲ

摘要: 三道题目都是比较基础的dp或者贪心的题目,除了第三个需要想一会,仔细分析题干才能发现玄机,其他的都是算法的基本应用。下面具体分析Best Time to Buy and Sell StockSay you have an array for which theithelement is the pr... 阅读全文

posted @ 2014-12-01 15:34 cha1992 阅读(133) 评论(0) 推荐(0) 编辑

[leetcode] Single Number II

摘要: Given an array of integers, every element appearsthreetimes except for one. Find that single one.Note:Your algorithm should have a linear runtime comp... 阅读全文

posted @ 2014-12-01 11:34 cha1992 阅读(134) 评论(0) 推荐(0) 编辑

[leetcode] Single Number

摘要: Given an array of integers, every element appearstwiceexcept for one. Find that single one.Note:Your algorithm should have a linear runtime complexity... 阅读全文

posted @ 2014-12-01 10:43 cha1992 阅读(105) 评论(0) 推荐(0) 编辑

导航