stack using linked list and deletion when no elements are present in list is done