A singly Linked list is a linear data structure where each element is a separate object. Each element or node of a Linked list is comprising of two items – the data and a reference to the next node. The last node has a reference to null. The entry point into a linked list is called the head of the list.
Array Vs Linked List :
|It is of fixed size||It is of dynamic size|
|Extra memory space is not required for strong address of next node as it is index based.||Extra memory space is required for strong address of next node.|
|inserting a new element at a specific position is costly,as new space need to be created and each elements need to be moved by 1 position ahead||insertion at any position is simpler|
|Random access is possible using index.||Random access is not possible|
|Supports binary search||Does not support binary search|
|insertion and deletion is not simple||insertion and deletion is simple|