leetcode summary 10/19

42. Trapping Rain Water https://gist.github.com/cd4159bf4d1b5d31fa27f13062e1681b 322. Coin Change https://gist.github.com/e383d1c66294ddc044a77e1a8e3ca529 518. Coin Change 2 https://gist.github.com/f4408eb706be4b337494af0dd0e24c47

System Design - Web Crawler

Guideline: The Crawler Service processes each page link by doing the following in a loop: 1. Takes the top ranked page link to crawl 2. Checks crawled_links in the NoSQL Database for an entry with a similar page signature 3. If we have a similar page, reduces the priority of the page link 1. This prevents us from getting into a cycle; Continue 2. Else, crawls the link - Adds a job to the Reverse Index Service queue to generate a reverse index - Adds a job to the Document Service queue to generate a static title and snippet - Generates the page signature - Removes the link from links_to_crawl in the NoSQL Database - Inserts the page link and signature to crawled_links in the NoSQL Database

leetcode summary 10/17

33. Search in Rotated Sorted Array https://leetcode.com/problems/search-in-rotated-sorted-array/discuss/ 341. Flatten Nested List Iterator generator, sepecific to this question stack, interative https://leetcode.com/problems/flatten-nested-list-iterator/discuss/ 155. Min Stack https://discuss.leetcode.com/topic/7020/java-accepted-solution-using-one-stack