Exam 16: Linked Lists

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

What is the purpose of the following code? current = head; While (current != NULL) { //Process current Current = current->link; }

(Multiple Choice)
4.9/5
(90)

Every node in a doubly linked list has two pointers: ____ and ____.

(Multiple Choice)
4.8/5
(76)

Each node of a linked list must store the data as well as the ____________________ for the next node in the list.

(Short Answer)
4.9/5
(87)

The link field of the last node of a linked list is ____.

(Multiple Choice)
4.9/5
(59)

The ____ deallocates the memory occupied by the nodes of a list when the class object goes out of scope.

(Multiple Choice)
4.9/5
(74)

A linked list is a random access data structure.

(True/False)
4.9/5
(91)

In a linked list,the address of the first node in the list is stored in a separate location,called the ____ or first.

(Multiple Choice)
4.8/5
(86)

The ____________________ constructor executes when an object is declared and initialized using another object.

(Short Answer)
4.9/5
(85)

struct nodeType { \quad int info; \quad nodeType *link; }; nodeType *head, *p, *q, *newNode; newNode = new nodeType; -Consider the accompanying code.What is the effect of the following statement? newNode->info = 50;

(Multiple Choice)
4.9/5
(78)

You can use the pointer head of a linked list to traverse the list.

(True/False)
4.7/5
(74)

For classes that include pointer data members,the assignment operator must be explicitly ____________________.

(Short Answer)
4.7/5
(78)

template <class Type> ____ doublyLinkedList<Type>::isEmptyList() const { \quad return (first == NULL); } -Consider the accompanying statements.The operation returns true if the list is empty; otherwise,it returns false.The missing code is ____.

(Multiple Choice)
4.7/5
(75)

Memory for the components of an array does not need to be contiguous.

(True/False)
4.9/5
(85)

Consider the following code: template <class Type> Int doublyLinkedList<Type>::length()const { ____ } The statement that provides the length of the linked list is ____.

(Multiple Choice)
4.7/5
(75)

Suppose that the pointer head points to the first node in the list,and the link of the last node is NULL.The first node of the linked list contains the address of the ____ node.

(Multiple Choice)
4.8/5
(81)

The length of a linked list is the number of nodes in the list.

(True/False)
4.8/5
(78)

A linked list in which the last node points to the first node is called a(n)____________________ linked list.

(Short Answer)
4.7/5
(87)

In a linked list,the order of the nodes is determined by the address,called the ____,stored in each node.

(Multiple Choice)
4.7/5
(76)

Each node of a singly linked list has two components: ____ and ____.

(Multiple Choice)
4.8/5
(66)

A(n)____________________ linked list is a linked list in which every node has a next pointer and a back pointer.

(Short Answer)
4.8/5
(93)
Showing 21 - 40 of 50
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)