Wednesday, June 14, 2017

Dairy

今天Lockheed Martin来电话了,说因为身份问题,把offer要收回去。HR真的太不专业了,浪费了我和公司的时间。还好我提前问了,要不然我真的drop了two week然后他再和我说这个,我就傻眼了。看来F35花400多亿美金还造不出来。是有原因的。 今天早上电面了彭博。题目本身不难但也不简单。考了两个题目。 1. Sliding Windows 变种 2. LRU 拿到题目有点紧张是真的。

[Leetcode]Best Time to Buy and Sell Stock 1


https://leetcode.com/problems/best-time-to-buy-and-sell-stock/#/description
The idea here is keep a currMin and iterate through whole prices list. Through each iteration, we update currMin and currMaxProfit