Browse Source

Merge pull request 'neuerZweig' (#1) from neuerZweig into main

Reviewed-on: #1
main
lauraF 3 years ago
parent
commit
ba1c346e22
  1. 7
      ArrayManipulation.java

7
ArrayManipulation.java

@ -5,7 +5,7 @@ import java.util.Arrays;
public class ArrayManipulation {
public static int[] reverseArray(int[] arr) {
public static int[] reverseArray(int[] arr, String name) {
for (int i = 0; i < arr.length/2; i++) {
int tmp = arr[i];
@ -17,8 +17,13 @@ public class ArrayManipulation {
}
public static void main(String[] args) {
<<<<<<< HEAD
int[] arr = {1,2,3,4,5};
System.out.println(Arrays.toString(reverseArray(arr, "Hannah")));
=======
int[] arr = {1,2,3,4,5,8};
System.out.println(Arrays.toString(reverseArray(arr)));
>>>>>>> 471ac3d389e5c3eabdfb385a6ad08f94a8b97c3b
}
public static int[] removeFirst(int[] arr) {