30. Select one: a. if(head->next == NULL) b. if(head == null) c. if( head == NUL
ID: 3693732 • Letter: 3
Question
30.
Select one:
a. if(head->next == NULL)
b. if(head == null)
c. if( head == NULL)
d. if( head->next==null);
e. if(head->next == NULL) and if( head->next==null);
f. if(head == null) and if( head == NULL)
12.
Given a linked list ( using the code from the book), which of the following sets of statements would implement a function to return the last item in the list?
Select one:
a.
NodePtr here;
here=head;
while(here ->link != NULL)
{
here=here ->link;
}
return here->data;
b.
NodePtr here;
here=head ->link
while(here ! = NULL)
{
here = here -> link;
}
return here->data;
c.
d.
2.
Given a linked list (using the code from the book) and assuming there are at least two nodes in the list, which of the following sets of statements would implement a function to return and remove the last item in the list?
Select one:
a.
b.
c.
d.
Explanation / Answer
30)c. if( head == NULL)
12) a.
NodePtr here;
here=head;
while(here ->link != NULL)
{
here=here ->link;
}
return here->data;
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.