Question: Please explain what each step does and when to use them Write a method that accepts an array of integers as a parameter and counts
Write a method that accepts an array of integers as a parameter and counts and returns the length of the longest sequence of repeated values using recursion. For example, the array 1,2,3,3,4,2,2,2,5 would return 3 because of the sequence 2,2,2 (length 3). If you need, you may write a driver method with a single array parameter and have it call your real" recursive method with more than one parameter. Use recursion only; no loops are allowed
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
