Skip to content

Commit 3e9dd66

Browse files
committed
2021-04-30
1 parent d765fcf commit 3e9dd66

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
class Solution(object):
2+
def checkIfPangram(self, sentence):
3+
"""
4+
:type sentence: str
5+
:rtype: bool
6+
"""
7+
return len(set(sentence)) == 26
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
class Solution(object):
2+
def maxIceCream(self, costs, coins):
3+
"""
4+
:type costs: List[int]
5+
:type coins: int
6+
:rtype: int
7+
"""
8+
costs.sort()
9+
for i in range(len(costs)):
10+
if coins < costs[i]:
11+
return i
12+
coins -= costs[i]
13+
return len(costs)

0 commit comments

Comments
 (0)