1
2
3
4
5
6
7
8
9
10
11
|
class Solution:
def plusOne(self, digits: List[int]) -> List[int]:
s=""
for i in digits:
s+=str(i)
s=int(s)+1
s=str(s)
tmp=[]
for i in s:
tmp.append(int(i))
return tmp
|
cs |
반응형
'python-algorithm' 카테고리의 다른 글
Leetcode 43. Multiply Strings (0) | 2021.07.15 |
---|---|
Leetcode 29. Divide Two Integers (0) | 2021.07.15 |
Leetcode 67. Add Binary (0) | 2021.07.15 |
Leetcode 69. Sqrt(x) (0) | 2021.07.15 |
백준 22193 Multiply (0) | 2021.07.15 |
댓글