doubly linked lists are useful for more than just inserting and removing elements at the head and tail of the listhowever they also are convenient for maintaining list of elements while allowing for insertion and removal in the middle of the list given node of doubly linked list (which could be possibly the header but not the trailer)we can easily insert new node immediately after specificallylet the be node following we execute the following steps make ' prev link refer to make ' next link refer to make ' prev link refer to make ' next link refer to this method is given in detail in code fragment and is illustrated in figure recalling our use of header and trailer sentinelsnote that this algorithm works even if is the tail node (the node just before the trailercode fragment inserting new node after given node in doubly linked list