1
"""
2
First of all, I'm making a few tuples using zip function.
3
Then extracting every created tuple. (for tup in zip())
4
After that, I can take numbers from the extracted tuples, in order to add them to a list and return. (for number in tup)
5
"""
6

7

8
class Solution:
9
def shuffle(self, nums: List[int], n: int) -> List[int]:
10
return [number for tup in zip(nums[:n], nums[n:]) for number in tup]

0

WPM •0 •0

100%

ACC •0 •0

0s

TIME •0