*Some important difference between Linear Array (LA) and Singly Linked List (SLL) to be remembered*

**1. In Linear Array we can have static memory allocation but Linked List have dynamic memory allocation with the help of NEW or malloc keywords.**

2. In Linear Array search the best, average and worst case complexity are O(1), O(n) and O(n) respectively while in Linked List is should be O(n).

2. In Linear Array search the best, average and worst case complexity are O(1), O(n) and O(n) respectively while in Linked List is should be O(n).

3. Insertion and Deletion of Linear array element is time consuming as compared to Linked List, so insertion and deletion is very easy in Linked List.

3. Insertion and Deletion of Linear array element is time consuming as compared to Linked List, so insertion and deletion is very easy in Linked List.

4. Linear Array is implemented only those situation in which we already know about total number of data element, but linked list is implemented where we don't know about the total number of data element in advance.

4. Linear Array is implemented only those situation in which we already know about total number of data element, but linked list is implemented where we don't know about the total number of data element in advance.

5. If the Linear array is not totally full then it may have reserve lots of memory without any use, but in Linked List we can not memory in advance. Due to that Linked list save memory.

5. If the Linear array is not totally full then it may have reserve lots of memory without any use, but in Linked List we can not memory in advance. Due to that Linked list save memory.

6. If the linear array is totally full then its total memory is used, in this case Linked list take more memory with equal number of element store. Because in LA only data element is stored but in SLL data element as well as linked pointer is also attached.

6. If the linear array is totally full then its total memory is used, in this case Linked list take more memory with equal number of element store. Because in LA only data element is stored but in SLL data element as well as linked pointer is also attached.

*Thanks*

*Mukesh Rajput*
## No comments:

## Post a Comment

Thanks

Mukesh Rajput