public void evensLeft( int [] array) (A Nick Parlante JavaBat problem) Modify th
ID: 3537402 • Letter: P
Question
public void evensLeft(int[] array)
(A Nick Parlante JavaBat problem) Modify the parameter array so it still contains the exact same numbers as the given array, but rearranged so that all the even numbers come before all the odd numbers. Other than that, the numbers can be in any order. You must modify the array arguments by changing array in method evensLeft. The array may be empty or have only one element. In both cases, no change should be made.
Original Array Modified Array
{1, 0, 1, 0, 0, 1, 1 } { 0, 0, 0, 1, 1, 1, 1 }
{3, 3, 2} { 2, 3, 3 }
{2, 2, 2} { 2, 2, 2 }
Explanation / Answer
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.