Linked List
Linked List
Linked List is a type of linear data structure. It is not like an array but instead linked list elements are not stored at a contiguous location. In linked list the elements are linked using pointers. A linked list is better than array in terms of insertion and deletion since linked list makes it easier to do that. A drawback about using Linked List is that it doesn't allow random access instead it has to access it sequentially starting from the 1st node. we cannot use binary search with linked list with its default implementation.
A Linked list is represented by a pointer on the 1st node of the linked list which is called the "head". If a linked list is empty the value of the head is NULL. Each node in a list consist of a minimal of 2 parts which is data and a pointer.
Linked List is a type of linear data structure. It is not like an array but instead linked list elements are not stored at a contiguous location. In linked list the elements are linked using pointers. A linked list is better than array in terms of insertion and deletion since linked list makes it easier to do that. A drawback about using Linked List is that it doesn't allow random access instead it has to access it sequentially starting from the 1st node. we cannot use binary search with linked list with its default implementation.
A Linked list is represented by a pointer on the 1st node of the linked list which is called the "head". If a linked list is empty the value of the head is NULL. Each node in a list consist of a minimal of 2 parts which is data and a pointer.
Comments
Post a Comment