• Courses
  • Tutorials
  • Jobs
  • Practice
  • Contests
September 20, 2023 |360 Views
SDE Sheet - Delete without head pointer
  Share   Like
Description
Discussion

This video is part of Linked List section under GFG SDE Sheet.

In this video, we are given, you are given a pointer/ reference to the node which is to be deleted from the linked list of N nodes. The task is to delete the node. Pointer/ reference to head node is not given. 
Note: No head reference is given to you. It is guaranteed that the node to be deleted is not a tail node in the linked list.

Example :

Input:
N = 2
value[] = {1,2}
node = 1
Output: 2

Explanation: After deleting 1 from the linked list, we have remaining nodes as 2.

Do check out:-

Article: https://www.geeksforgeeks.org/delete-a-node-from-Linked-list-without-head-pointer/
Problem: https://practice.geeksforgeeks.org/problems/delete-without-head-pointer/1
SDE Sheet: https://www.geeksforgeeks.org/sde-sheet-a-complete-guide-for-sde-preparation/

Read More