I have a linked list, that I want to remov things off the top like a stack....
I made this function but it doesn't work...
does anyone know what I'm doing wrong?
Code:STUDENT* remv_student( STUDENT* ptr ) { static STUDENT popped_student; popped_student = *top; ptr = top; top = top -> studentPtr; free (ptr); --students_enrolled; return &popped_student; }