bsc

Comprehensive codebase and cou...
Log | Files | Refs | Activity | README | LICENSE

root / semester_2 / algorithms / algo_002.md

algo_002.md (351B)


      1 # algo_002
      2 
      3 ### Problem Statement
      4 
      5 > Write an algorithm to delete the first node of the list.
      6 
      7 ## Algorithm
      8 ```
      9 procedure delete_firstNode(head)
     10 begin
     11     if(head = NULL)
     12         write("List is empty, Deletion is not possible.");
     13     else 
     14         p ← head ;
     15         head ← next(p);
     16         delete(p);
     17     endif
     18     return(head);
     19 end procedure
     20 ```
© notamitgamer • Site Built: 2026-09-05 01:53:16 UTC • git-mirror commit: c170d72 [view raw info]
Originally created with stagit • modified by notamitgamer
Forked from github.com/notamitgamer/git-mirror