template<class T>
int List<T>::Length()const{
LinkNode<T> *current = first->link;
int k=0;
while(current->link!=NULL) //扫描链表到尾部
{
current = current->link;
k++;
}
return k;
}
template<class T>
int List<T>::Length()const{
LinkNode<T> *current = first->link;
int k=0;
while(current->link!=NULL) //扫描链表到尾部
{
current = current->link;
k++;
}
return k;
}