2020年4月7日

摘要: Given an integer array arr, count element x such that x + 1 is also in arr. If there're duplicates in arr, count them seperately. Example 1: Example 2 阅读全文
posted @ 2020-04-07 23:08 codingEskimo 阅读(198) 评论(0) 推荐(0)
摘要: Given an array of strings, group anagrams together. Example: Note: All inputs will be in lowercase. The order of your output does not matter. 这道题就是用每个 阅读全文
posted @ 2020-04-07 08:29 codingEskimo 阅读(124) 评论(0) 推荐(0)
摘要: Say you have an array for which the ith element is the price of a given stock on day i. Design an algorithm to find the maximum profit. You may comple 阅读全文
posted @ 2020-04-07 07:54 codingEskimo 阅读(126) 评论(0) 推荐(0)
摘要: Say you have an array for which the ith element is the price of a given stock on day i. If you were only permitted to complete at most one transaction 阅读全文
posted @ 2020-04-07 07:50 codingEskimo 阅读(115) 评论(0) 推荐(0)

导航