Am lierally veru much confused

in the video of insertion at tail bhaiya said that to reach the last node we did temp->next !=NULL by doing thus we reach our last node but here in this video bhaiya is saying by doing temp->next =head by doing this we reach second last position

@Aditya-Kushwaha-914550392281281 if you are confused about anything, just pick up a pen and paper and dry run it. Pointers can be tricky to deal with and dry run will give you a lot of clarity.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.