Skip to content

Commit 65cc534

Browse files
Create 2942.py
1 parent ce7e54b commit 65cc534

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

2501-3000/2942.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
class Solution:
2+
def findWordsContaining(self, words: List[str], x: str) -> List[int]:
3+
res = []
4+
for i in range(len(words)):
5+
if x in words[i]:
6+
res.append(i)
7+
return res

0 commit comments

Comments
 (0)