- Given an array of int, two people can only pick at the beginning or end, if you go first how to get maximum sum. code link
- 给一个删除树节点的函数,和root,怎么遍历删除整棵树 code link
- Given a sorted array,find occuring time more than n/4 times popular number. code link
- 输出任意permutation使得List中的相同element的间距要小于minDistance code link
- 给一个词典和一个target word,问这个word是不是smashable. smashable的定义是这个词在字典里并且它不停地任意删除一个字母得到的单词也在词典里. code link
#Linkin
- Update a set of (upto) K elements, when you see a new element from an incoming stream, to ensure that every element seen so far, has an equal chance of making it into the set of K elements that we are maintaining. code
- Sparse matrix multiplication. code
#Yahoo
- 给一个链表8->2->4 表示时间1,8号叶子浮上来,时间2,2号叶子浮上来,时间3,4号叶子浮上来;叶子一旦浮上来,就一直在。有一个青蛙从起点开始,最远能跳k步,河岸宽是width. 青蛙在叶子间跳跃不需要时间. 问青蛙最快什么时候能过河. code