M
Mike Copeland
I'm confused about how to sort a list on an element of the list's
structure. Here is my data definition:
struct Finishes // computed Finish information
{
long netTime;
int bibNumber;
} fWork;
typedef list<Finishes> FINISHES;
FINISHES finishInfo;
list<Finishes>::iterator fIter;
I have populated the list successfully, and now I want to sort the
list on the netTime element. All examples of the list.sort I've found
work only with scalars or single-element structures. How do I do this
with my data? TIA
structure. Here is my data definition:
struct Finishes // computed Finish information
{
long netTime;
int bibNumber;
} fWork;
typedef list<Finishes> FINISHES;
FINISHES finishInfo;
list<Finishes>::iterator fIter;
I have populated the list successfully, and now I want to sort the
list on the netTime element. All examples of the list.sort I've found
work only with scalars or single-element structures. How do I do this
with my data? TIA