1
2
3
4
5
6
7
|
class Solution:
def shuffle(self, nums: List[int], n: int) -> List[int]:
tmp=[]
for i in range(n):
tmp.append(nums[i])
tmp.append(nums[n+i])
return tmp
|
cs |
반응형
'python-algorithm' 카테고리의 다른 글
Leetcode 28. Implement strStr() (0) | 2021.07.13 |
---|---|
Leetcode 1512. Number of Good Pairs (0) | 2021.07.13 |
Leetcode 1431. Kids With the Greatest Number of Candies (0) | 2021.07.13 |
Leetcode 9. Palindrome Number (0) | 2021.07.12 |
Leetcode 7. Reverse Integer (0) | 2021.07.12 |
댓글