|
Re: Alphabetical programme
|
Posted: Apr 8, 2002 10:47 AM
|
|
Kelly, When you first posted this request, I thought I ought to look into what was needed, as I didn't know how to answer. I learned a LOT in looking around - and I found a few different ways to do this. In java.util.Array, the Array.sort() method works well. And putting the names into a Vector and using the Collections.sort() method in java.util.Vector works really nicely, too. Just look at the java API docs on the Sun site (like the ones at http://java.sun.com/j2se/1.4/docs/api/index.html). This is a rather simple assignment - basically, the method call does most of the work, all you need do is get the array/vector set up and then the results printed out - are you sure there isn't more to it?
Lynn.
|
|