Operations that can be performed on singly linked lists include insertion, deletion and traversal.Ī doubly linked list whose nodes contain three fields: an integer value, the link forward to the next node, and the link backward to the previous nodeĪ technique known as XOR-linking allows a doubly linked list to be implemented using a single link field in each node. Singly linked lists contain nodes which have a data field as well as 'next' field, which points to the next node in line of nodes. In Lisp and some derived languages, the next node may be called the 'cdr' (pronounced could-er) of the list, while the payload of the head node may be called the 'car'. The 'tail' of a list may refer either to the rest of the list after the head, or to the last node in the list. The remaining fields are known as the 'data', 'information', 'value', 'cargo', or 'payload' fields. The field of each node that contains the address of the next node is usually called the 'next link' or 'next pointer'.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |