function to delete the first node in the link list

guys;
please help with this.
a function to delete the first node in a linked list
it does not display the info. thanks.
1
2
3
4
5
6
7
8
void deletefirstnode(Station*CurrentPointer, Station*StartPointer)
{
CurrentPointer=StartPointer->Nextp;
StartPointer->Nextp=NULL;
delete StartPointer;
StartPointer=NULL;
StartPointer=CurrentPointer;
}
Without more info about how your linked list class looks, I'd only be guessing about what you need to do.

BTW, why not use std::list instead of trying to create your own?
Topic archived. No new replies allowed.