Here is my little sourcecode. It works but i need help at method call. I dont know "how to" enter the values. I make "new SmallestElement ()" and try to call the method. the message i get:
What i have to write in the boxes? Can someone make an example?
public class SmallestElement {
public int getSmallestElement(int[] array, int start, int ende) {
int mitte = (start + ende) / 2;
if(start == ende) {
return array[start];
} else {
return Math.min(getSmallestElement(array, start, mitte), getSmallestElement(array, mitte+1, ende));
}
}
}