Month: October 2018
931 Minimum Falling Path Sum
Link 931.Minimum Falling Path Sum Thought DFS When first seeing this question, DFS prompt into my mind directly. Take Any node from first level as start, and search down stream. Until reach node in last level. For any path, it will have a value. Find the minimum value and it will be the answer However, for […]
Read More → 931 Minimum Falling Path Sum929. Unique Email Addresses
Link: Unique Email Addresses Thought Brutal Force SolutionThis question is pretty simple (and it actually is an esay one). A naive approache is, split the name and domain. For the name, remove every thing after first ‘+’, and then replace all ‘.’ as empty. For the domain, just keep it is. Then, use a set […]
Read More → 929. Unique Email Addresses