Puedes seguirnos en

BUSCADOR

Engineering

Comparison between Array representation and linked representation of Queue

Maximum size of the queue is fixed at the time of compilation, when the queue is represented using an array, this causes wastage of storage space. If the queue size is arbitrarily large and if less area us reserved for the queue then there will be a problem overflow.

In case if a queue using linked structure, no memory area is reserved in advanced. Memory for a node is acquired during run time, whenever a fresh insertion  is to be made. There is no problem of overflow. As long as the system has free memory it can be given for a queue element.

Array representation is simple to implement whereas the linked representation requires additional knowledge of linked list and dynamic data structure. Many programming languages do not support dynamic data structure.

In linked representation, additional memory is required to store the address of next element. There is no such requirement in case of array representation of a queue, as array is stored in contiguous memory location.

Anuncio publicitario

Escrito por

Administrador de ENGGDRCAOS. Canal dedicado especialmente a la formación del estudiante que aspira a ser ingeniero. Todos los videos son Ingles. Apasionado del universo Apple, estudiante de Ingeniería y Gamer por vocación.

Publicidad

ARTÍCULOS RELACIONADOS

Engineering

Interrupt is a signal sent to the processor by a software or an hardware, which has a high priority. An interrupt causes the microprocessor...

Engineering

Singly linked list is a dynamically allocated list, which consists of one or more nodes. Each node contains a pointer which holds the address...

Engineering

Singly linked list is a type of list which uses dynamic representation rather than a much simpler and versatile static representation. Dynamic representation is...

Engineering

Queue is a very useful data structure. Various features of operating system are implemented using queue. Scheduling of processes (Round Robin Algorithm) Spooling (to...