// Introduction to Software Testing // Authors: Paul Ammann & Jeff Offutt // Chapter 9; page 13 // Can be run from command line // No JUnit tests at this time. import java.io.*; public class FindVal { /** * Find last index of element * * @param numbers array to search * @param val value to look for * @return last index of val in numbers; -1 if absent * @throws NullPointerException if numbers is null * Note: Same specification as findLast, but slightly different implementation */ public static int findVal(int numbers[], int val) { int findVal = -1; for (int i=0; i