Skip to content

Commit f78781b

Browse files
Create: 1929-concatenation-of-array.ts
1 parent c3fc8cd commit f78781b

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

Diff for: typescript/1929-concatenation-of-array.ts

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
function getConcatenation(nums: number[]): number[] {
2+
let result: number[] = [];
3+
4+
for(let i = 0; i < 2; i++) {
5+
nums.forEach(num => result.push(num));
6+
};
7+
8+
return result;
9+
};

0 commit comments

Comments
 (0)