You haven't said what class this is for. I presume the class is not associated with any particular language. If that were the case, there would be no choice. The way you described the problem doesn't suggest any one language over any other so the question then becomes, what language are you the most familiar with? What software do you have available? What is your skill set?
If you are running Windows then you can develop a solution in vbScript without having to install anything else. You could also install Python, although that would require more effort on your part. Another possibility is vb.Net which would require even more effort.
We also don't know what the input looks like. Is the data in a text file, or a database? The more effort you put into asking the question, the more we are able to help.
In the mean time, please read this thread for suggestions on how to post meaningful questions.