Question 1
How many pointers are needed to build a linked list in a backward manner?
a. one
b. two
c. three
d. four
Question 2
Every node (except of the last node) in a singly linked list contains ____.
a. the address of the previous node
b. the address of the next node
c. no address information
d. the next node
Question 3
The length of a linked list is the number of nodes in the list.
True
False
Question 4
In a doubly linked list, item insertion requires updating four pointers in certain nodes.
True
False
Question 5
Linked lists allow you to overcome the size limitations of an array data type.
True
False
Question 6
In a linked list, the address of the first node in the list is stored in a separate location, called the ____ or first.
a. pointer
b. top
c. front
d. head
Question 7
Which of the following is a basic operation on singly linked lists?
a. Make a copy of the linked list
b. Determine whether the list is full
c. Swap the head and the last nodes
d. Retrieve the data of an arbitrary node
Question 8
Each node of a singly linked list has two components: ____ and ____.
a. info; head
b. link; back
c. back; head
d. info; link
Question 9
Building a linked list forward requires exactly two pointers.
True
False
Question 10
Every node in a doubly linked list has two pointers: ____ and ____.
a. current; next
b. previous; next
c. back; next
d. previous; current
Question 11
Memory for the components of an array does not need to be contiguous.
True
False
Question 12
Data can be organized and processed sequentially using an array, called a(n) ____ list.
a. ascending
b. ordered
c. sequential
d. linked
Question 13
What is the purpose of the following code?
current = head;
while (current != NULL)
{
//Process current
current = current->link;
}
a. Insertion of a node
b. Traversal of a linked list
c. Selection of a node
d. Creation of a new list
Question 14
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.
a. tail
b. second
c. first
d. head
Question 15
To insert an item into a linked list, the address in each node must be changed.
True
False
Question 16
When you build a linked list in the backward manner, a new node is always inserted at the end of the linked list.
True
False
Question 17
You can use the pointer head of a linked list to traverse the list.
True
False
Question 18
In a linked list, if a new item is always inserted in the beginning or in the end of the list and the data we read is unsorted, the linked list will be unsorted.
True
False
Question 19
The statement p->link = p->link->link; removes a node from the linked list and deallocates the memory.
True
False
Question 20
In a doubly linked list, the function search returns true if searchItem is found in the list.
True
False