QUESTION 69 In the implementation of MyLinkedList, MyLinkedList has a capacity p
ID: 3714461 • Letter: Q
Question
QUESTION 69
In the implementation of MyLinkedList, MyLinkedList has a capacity property.
True
False
QUESTION 70
A heap can be set up in such a way, where each node is greater than or equal to any of its children.
True
False
QUESTION 71
A binary tree is complete if every level of the tree is full except that the last level may not be full and all the leaves on the last level are placed left-most.
True
False
QUESTION 72
In the implementation of MyArrayList, size never reduces.
True
False
QUESTION 74
In the implementation of MyStack, MyStack contains all the methods defined in MyArrayList.
True
False
QUESTION 75
In the implementation of MyLinkedList, Node has a property named next that links to the node after this node.
True
False
QUESTION 76
In the implementation of MyArrayList, if the current capacity equals to size, capacity is doubled when a new element is added to MyArrayList.
True
False
QUESTION 77
You should always choose a pivot that divides the list evenly.
True
False
QUESTION 79
Given a heap, to remove the root, you need to start a process by first placing the last node in the heap to the place of the root and move it down to maintain the heap property.
True
False
QUESTION 80
ArrayList is more efficient than LinkedList, when inserting/deleting an element in the beginning of the list.
True
False
QUESTION 81
In the implementation of MyArrayList, size is not declared in MyArrayList, but declared in MyAbstractList as protected.
True
False
Given a heap, to remove the root, you need to start a process by first placing the smaller child of the root to the place of the root and move it down to maintain the heap property.
True
False
QUESTION 84
A pivot divides a list into two sublists of equal size.
True
False
QUESTION 85
To add a new node to a heap, you need to start a process by first placing it as the right child of the root and move it up to maintain the heap property.
True
False
QUESTION 88
ArrayList is more efficient than LinkedList, when retrieving an element given the index.
True
False
QUESTION 89
A stack can be viewed as a special type of list, where the elements are accessed, inserted, and deleted only from the end, called the top, of the stack.
True
False
QUESTION 90
In the implementation of MyLinkedList, MyLinkedList contains all the methods defined in MyList. Additionally, MyLinkedList defines several new methods that are appropriate for processing a linked list.
True
False
QUESTION 91
In the implementation of MyArrayList, capacity is always greater than size.
True
False
QUESTION 92
In the implementation of MyStack, MyStack contains an array list for storing elements.
True
False
QUESTION 93
In the implementation of MyLinkedList, MyLinkedList has the properties named first and last to point to the nodes in a linked list.
True
False
QUESTION 94
Time complexity analysis is often for the worst case, since the best-case is not representative.
True
False
QUESTION 96
ArrayList is more efficient than LinkedList, when inserting/deleting an element at the end of the list.
True
False
QUESTION 97
You can use a linked list to improve efficiency for adding and removing an element anywhere in a list.
True
False
QUESTION 99
In the implementation of MyArrayList, size is reduced by 1 if an element is deleted from the list.
True
False
Explanation / Answer
QUESTION 69
In the implementation of MyLinkedList, MyLinkedList has a capacity property.
True
QUESTION 70
A heap can be set up in such a way, where each node is greater than or equal to any of its children.
True
QUESTION 71
A binary tree is complete if every level of the tree is full except that the last level may not be full and all the leaves on the last level are placed left-most.
True
QUESTION 72
In the implementation of MyArrayList, size never reduces.
False
QUESTION 74
In the implementation of MyStack, MyStack contains all the methods defined in MyArrayList.
True
QUESTION 75
In the implementation of MyLinkedList, Node has a property named next that links to the node after this node.
True
QUESTION 76
In the implementation of MyArrayList, if the current capacity equals to size, capacity is doubled when a new element is added to MyArrayList.
True
QUESTION 77
You should always choose a pivot that divides the list evenly.
True
QUESTION 79
Given a heap, to remove the root, you need to start a process by first placing the last node in the heap to the place of the root and move it down to maintain the heap property.
True
QUESTION 80
ArrayList is more efficient than LinkedList, when inserting/deleting an element in the beginning of the list.
False
QUESTION 81
In the implementation of MyArrayList, size is not declared in MyArrayList, but declared in MyAbstractList as protected.
True
Given a heap, to remove the root, you need to start a process by first placing the smaller child of the root to the place of the root and move it down to maintain the heap property.
False
QUESTION 84
A pivot divides a list into two sublists of equal size.
False
QUESTION 85
To add a new node to a heap, you need to start a process by first placing it as the right child of the root and move it up to maintain the heap property.
False
QUESTION 88
ArrayList is more efficient than LinkedList, when retrieving an element given the index.
True
QUESTION 89
A stack can be viewed as a special type of list, where the elements are accessed, inserted, and deleted only from the end, called the top, of the stack.
True
QUESTION 90
In the implementation of MyLinkedList, MyLinkedList contains all the methods defined in MyList. Additionally, MyLinkedList defines several new methods that are appropriate for processing a linked list.
True
QUESTION 91
In the implementation of MyArrayList, capacity is always greater than size.
True
QUESTION 92
In the implementation of MyStack, MyStack contains an array list for storing elements.
True
QUESTION 93
In the implementation of MyLinkedList, MyLinkedList has the properties named first and last to point to the nodes in a linked list.
True
QUESTION 94
Time complexity analysis is often for the worst case, since the best-case is not representative.
True
QUESTION 96
ArrayList is more efficient than LinkedList, when inserting/deleting an element at the end of the list.
True
QUESTION 97
You can use a linked list to improve efficiency for adding and removing an element anywhere in a list.
True
QUESTION 99
In the implementation of MyArrayList, size is reduced by 1 if an element is deleted from the list.
True
Answers are added in BOLD
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.