Linked List Programming Problems

  1. ListNode Class to create a node of a linked list

In the Linked List Class:

  1. add(Listnode node) function to add a new node at the end of the linked list
  2. print() function to print the entire linked list
  3. delete(Listnode node) function that deletes the node passed as a parameter
  4. findLength() function that returns the length of the linked list
  5. getMiddle() function that returns the middle node value
  6. insert(ListNode node, int i) function that inserts ‘node’ at the ith position of a linked list
    (taking head to be index 0)

Additional Problems:

  1. Flatten a Linked List
  2. Delete Alternating nodes
  3. Check if the linked list is circular
  4. Sum of last N nodes
  5. Implement stack using a linked list
  6. Modular Node
  7. Reverse a linked list

Leave a Reply

PHP JS HTML CSS BASH PYTHON CODE

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this:
search previous next tag category expand menu location phone mail time cart zoom edit close