diff --git a/771-jewels-and-stones/771-jewels-and-stones.py b/771-jewels-and-stones/771-jewels-and-stones.py new file mode 100644 index 0000000..74a974c --- /dev/null +++ b/771-jewels-and-stones/771-jewels-and-stones.py @@ -0,0 +1,3 @@ +class Solution: + def numJewelsInStones(self, jewels: str, stones: str) -> int: + return sum([stones.count(j) for j in jewels]) \ No newline at end of file