Skip to content

Commit 2d666a6

Browse files
committed
Time: 0 ms (100%), Space: 17.9 MB (70.25%) - LeetHub
1 parent b1bbcf4 commit 2d666a6

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# time complexity: O(1)
2+
# space complexity: O(1)
3+
from typing import List
4+
5+
6+
class Solution:
7+
def getConcatenation(self, nums: List[int]) -> List[int]:
8+
return nums * 2
9+
10+
11+
nums = [1, 2, 1]
12+
print(Solution().getConcatenation(nums))
13+
nums = [1, 3, 2, 1]
14+
print(Solution().getConcatenation(nums))

0 commit comments

Comments
 (0)