i have class like this
and List<T> has x,y,valueCode:template class<T>
class A{
private:
T m;
T n;
List<T> *start;
List<T> *end;
public:
...
}
how can i sort this doubly linked list according to x,y values?
Printable View
i have class like this
and List<T> has x,y,valueCode:template class<T>
class A{
private:
T m;
T n;
List<T> *start;
List<T> *end;
public:
...
}
how can i sort this doubly linked list according to x,y values?
Perhaps you could post the definition of 'List', and give an example of a type that you would use for T.
Do you know how to write a less-than operator?
Why do you not use a std::list, and why are 'start' and 'end' pointers to Lists rather than just straight members?