Linked Lists

Description

Quiz Linked Lists Good Luck!
José Miguel Gallardo
Quiz by José Miguel Gallardo, updated more than 1 year ago
José Miguel Gallardo
Created by José Miguel Gallardo about 9 years ago
96
0

Resource summary

Question 1

Question
How is the procedure of adding a new node in a linked list of size 2 between the existing nodes?
Answer
  • Create the new node, link it to the first one and link the new one to the last one.
  • Create the new node, move the last one to the right, and place the node between them.
  • Create the new node, link it to the last one, and link the first one to the new one.

Question 2

Question
If a programmer wants to print the data of a linked list in reverse order, what type of linked list should he/she use in order to maximise efficiency?
Answer
  • Linear Linked List
  • Two-Way Linked List
  • Circular Linked List

Question 3

Question
What does dynamic data structure do to manage memory and where does it keep it?
Answer
  • It creates a virtual memory in the hard drive that can be used by any program when needed.
  • It creates static blocks of memory in the RAM that is always used by a program.
  • It creates blocks of memory in the heap that can be used by any program.

Question 4

Question
It is a disadvantage of linear linked lists (Check only one box)
Answer
  • It can only be browsed forward and backwards, so you can't use an ekement by calling its position.
  • It uses two values in each node, instead of only one as an array... Needless to say, it requires more memory.
  • It always uses the same amount of memory because it is linear.

Question 5

Question
Check the box of two advantages of using a static data structure
Answer
  • Memory allocation is fixed so there won't be any problem to add/remove items
  • Easier to program
  • No viruses
  • Less use of memory

Question 6

Question
Choose one disadvantage of using dynamic data structures (Only check one box)
Answer
  • Can be inefficient and time consuming
  • There is a fixed size
  • It could overflow and underflow
  • All of the above

Question 7

Question
Each node contains two fields: A "data" field to store any data the element holds and a "next" field which is a place used to link one node to the next one.
Answer
  • True
  • False

Question 8

Question
Choose the diagram that represents a linear linked list

Question 9

Question
Choose the diagram that represents a two-way linked list

Question 10

Question
Choose the diagram that represents a circular linked list

Question 11

Question
It is possible to delete a value in the middle of a linked list and then to re-link all the list
Answer
  • True
  • False

Question 12

Question
Which is the right combination (linked list type/Data structure) to represent a queue?
Answer
  • Circular/Static
  • Circular/Dynamic
  • Linear/Static
  • Linear/Dynamic
Show full summary Hide full summary

Similar

Linked Lists WedW15
Madeline Harlow
Linked Lists WedW15
Neyavanan v
Linked Lists WedW15
Neyavanan v
Linked Lists WedW15
Neyavanan v
Linked Lists WedW15
Kunall Banerjee
CHEMISTRY C1 6
x_clairey_x
Psychology flashcards memory
eharveyhudl
Romeo and Juliet: Key Points
mbennett
Key Biology Definitions/Terms
courtneypitt4119
New English Literature GCSE
Sarah Egan
EXAM 1 - ENABLING FEATURES
kristinephil558