Hi.

I need to write a program to sort data from .dat file. The following is how the data in the file looks like:

5
7
2
13
11

It is required to pass each above as an object to a "SortItem"method, such like:

public void SortItem (Object o) {

// Use linked list and compareTo to sort the object.

}

The object is successfully passed, but the main problem is that I don't know how to use linked list to sort it. Would you show me how to do it? Or give me an example?

Thanks a lot!!!