CIS135-41
Linear Data Structures assignment questions
- A linked list is useful when you need to remove and item or put an item in the middle. They are also helpful when you do not know how many items are going to be in the linked list.
- A stack keeps track of items using Last in First Out, meaning that the last element to be entered is the first element to come out. A queue keeps track of items using First in First Out, meaning that the first element entered in is thne first element you get out.
- A developer would use a stack when they need to temporarily store data.
- When you know how long the list is and want to optimize it, you use an array.