create java application can count 1 10 using looping control structure , returns value 10-element sized single-dimensional array.
public int[] getnumberedarray(){ int[] array = new int[10]; for(int = 1; <= 10; i++){ array[i-1] = i; } return array; }
that should it, if homework, please understand every aspect of method, why works, , different parts of grasp.
school suppose challenge learn, having work done waste of valuable learning experience.
Comments
Post a Comment