Skip to content

Commit 0588c2e

Browse files
authored
Update 1929-concatenation-of-array.go
1 parent 4c0e22e commit 0588c2e

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

go/1929-concatenation-of-array.go

-2
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
func getConcatenation(nums []int) []int {
22
n := len(nums)
33
ans := make([]int, 2*n) //lets make an array of int type and 2*n size
4-
54
i := 0
65
for i < n { //implementing for loop for the given condition
76
ans[i] = nums[i]
87
ans[i+n] = nums[i]
98
i++
109
}
11-
1210
return ans
1311
}

0 commit comments

Comments
 (0)