We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7741235 + 9d45c48 commit c319232Copy full SHA for c319232
java/1929-concatenation-of-array.java
@@ -0,0 +1,10 @@
1
+class Solution {
2
+ public int[] getConcatenation(int[] nums) {
3
+ int[] ans = new int[nums.length*2];
4
+ for(int i=0;i<nums.length;i++) {
5
+ ans[i] = nums[i];
6
+ ans[i+nums.length] = nums[i];
7
+ }
8
+ return ans;
9
10
+}
0 commit comments