CPE 103

Recursion Lab 1


For this lab you will be writing five very small recursive methods. You must use recursion, iteration is not allowed.

1. You are to implement the five methods in the class RecursionLab according to the javadoc provided.  Be sure your public interface matches the specifications.

2. The RecursionLab class has five static methods.  In order of difficulty to write (easy to hard), they are
  1. arrayTotal
  2. arrayPosTotal
  3. countSpaces
  4. findMax
  5. isPalindrome

3. Create a JUnit test class to exercise your methods and verify their correctness.

4.  Submit the source code for your RecursionLab class and JUnit class.  Submit output from running your JUnit tests.  You do not need to write a driver of submit system tests.