Remove Last Element In Linked List | FREE DSA Course in JAVA | Lecture 98

Поділитися
Вставка
  • Опубліковано 8 бер 2023
  • In this lecture, we will see how we can remove the last element or node in the linked list.
    There will be three cases for the same:-
    1. The linked list is empty
    2. The linked list is having one element
    3. The linked is having multiple elements
    For each case we have to perform operations like
    Case 1 - We have to do nothing as it doesn't have any element
    Case 2 - We have to just point the head to null to make it an empty linked list
    Case 3 - We have to make the address part of the last-second element null.
    These are simple operations we need to do in order to perform the required operation of removing the last node/element from the linked list.
    Let's see the code in java for this particular operation.
    Subscribe ‪@TAPACADEMY‬
    For more information, fill out this form: forms.gle/8eiUmM92Fx563Aen9
    or call us at 8884881203
    Facebook: / thetapacademy
    Instagram: / tapacademy_online
    Linkedin: / 73820805
    Website: www.thetapacademy.com​
    #java #linkedlist #linkedlists #javaprogramming #coding #coder #javaprogram #itjobs #dsa #dsacourse #placement

КОМЕНТАРІ • 2

  • @dipayanbhattacharjee8935
    @dipayanbhattacharjee8935 6 місяців тому

    Why did you stop uploading videos in this series it is probably one of the best videos available for free.

  • @user-bl9ph5eg7z
    @user-bl9ph5eg7z 4 місяці тому

    sir please upload more topics of dsa with java