Remove All Occurrences
Write a method removeAll that takes an ArrayList and an int target, and removes ALL occurrences of target from the list. The method modifies the list in place and returns nothing.
Remove Duplicates
Write a method removeDuplicates that takes an ArrayList and removes duplicate values, keeping only the first occurrence of each. Modifies the list in place.
Shift Left
Write a method shiftLeft that takes an int[] and shifts every element one position to the left. The first element wraps around to the last position.
Reverse Array In Place
Write a method reverse that reverses an int[] in place. Do not create a new array.
Filter to New List
Write a method filterAbove that takes an int[] and an int threshold, and returns a new ArrayList containing only elements greater than threshold.
Count Long Strings
Write a method countLong that takes a String[] and an int minLen, and returns the number of Strings whose length is greater than or equal to minLen.
Swap Adjacent Pairs
Write a method swapPairs that takes an int[] and swaps every pair of adjacent elements. If the array has odd length, the last element stays in place.
Row Sums (2D Array)
Write a method rowSums that takes a int[][] and returns a new int[] where each element is the sum of the corresponding row.
Want Structured FRQ Practice Every Day?
The 4-Week Cram Kit includes daily FRQ drills with scoring rubrics for every problem type.
Get the Cram Kit — $29.99 1-on-1 Tutoring