Fixed-size Array: _____ for adding new entry right after the last entry (known i
ID: 3868948 • Letter: F
Question
Fixed-size Array: _____ for adding new entry right after the last entry (known index). _____ for unspecified remove - known index (removes last entry) _____ for removing a specific entry - Unknown index(search and compile until found). _____ for resizing. Linked Chain: _____ for adding new node to the beginning of chain (always referenced by the head) _____ for removing unspecified-known first node (removes first node). _____ for removing a specific entry - Unknown node(search and compare until found). _____ for requires more memory than array of same length. Each node in the chain stores two references, one to the data and one to the next node in the chain. A Stack: A collection of objects in reverse chronological order. Implementation: 1-Array: By maintaining the stack bottom entry as a First location in the array. All operations (push, pop, peek are _____. Resizing is _____. If spread over all other pushes and if not frequent then push is almost _____ 2- Vector: Can resize dynamically and have same performance of the array-based implementation _____. 3-Linked: First node in the chain references the stack's top node which result in all operations (push, pop, and peek) are _____.Explanation / Answer
Implementation of Queue:
Array Implementation:
1)Rear for adding new entry right after the last entry.(Enqueue)
2)Delete is for removing unlnown index
3) Search for removing the known and searched index.
4)Resizing method is used for resizing.
2)linked Chain:
STACK:
1)Array
2)Vector:
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.