Answer, and explain: For large lists, which of the following is true of inserting a new item into a linked list compared to insertion in an array? What of small lists?
a. more efficient.
b. less efficient.
c. about the same.
d. depends on the size of the two lists.
The best answer is d) depends on the size of the two lists. For large lists, part a), more efficient is correct, for small lists, part c), about the same is correct.
Explanation: Part a) Inserting a new item into a large linked list is more efficient than insertion into a large array. If we are inserting into a list, you have about 5 operations, most of which are pointer assignments, regardless of the list size. If you insert into an array, on the average, you have to move about half the array entries to insert a data item. For small lists, the answer is c) about the same.
You might also like to view...
The prefix ____ is used for representing a thousand trillion.
A. tera- B. exa- C. giga- D. peta-
After you resize a datasheet's columns, you must ____________________ the table with the layout changes to keep the new column widths.
Fill in the blank(s) with the appropriate word(s).
_____, a free cloud-based project management tool, runs in a browser window, so there is no software to install to use it.
A. Apptivo B. Smartsheet C. Microsoft Project D. GantterĀ
You should create a formal checklist of your procedures that's applied to all your cases or include such a checklist in your report.
Answer the following statement true (T) or false (F)