Class Assignment 4A

Arrays and Searching

Due on Friday, April 9, 2004

A linear search is the process of searching an unsorted array for a particular value.  Write a program that will read a text file of 15 license plate numbers into a String array and then allow the user to input a license plate to search for.  To keep things simple, each license plate number will consist of three upper case letters followed by four numbers.  An example would be: TOP5432

Include a method called linearSearch that accepts a String license plate number and a String array.  The method should return the location in the array of where the plate is found or an appropriate message if the plate is not found.

Evaluation:

Documentation                                  /4
File Handling                                    /4
Use of Arrays                                  /4
Linear Search                                   /4
Correct Solution to Test Data           /4

Total                                              /20

Submission method:  Electronically to the class submissions folder

Hosted by www.Geocities.ws

1