python concise dfs solution
```\nclass Solution:\n    def findAllConcatenatedWordsInADict(self, words: List[str]) -> List[str]:#dfs to search.\n        def dfs(w,oneGood):#return True or F
```\nclass Solution:\n    def findAllConcatenatedWordsInADict(self, words: List[str]) -> List[str]:#dfs to search.\n        def dfs(w,oneGood):#return True or False\n            if w in Set and oneGood:\n                return True\n            if w in memo:\n                return memo[w]\n            for i in range(len(w)-1):#[:i+1] and [i+1:] part \n                if w[:i+1] in Set and dfs(w[i+1:],True):\n                    memo[w]=True\n                    return True\n            memo[w]=False\n            return False  \n        \n        memo={}#cache visited word\'s result \n        res=[]\n        Set=set(words)\n        for w in words:\n            if dfs(w,False):\n                res.append(w)\n        return res
[]