Deletion in linked list

i understand the concept of linked list but i find difficulty while makind code foe deletion at tail and middle can you send me its code

@shrutikatyal

I am not allowed to send the entire code. I can however discuss the concept. If you have you delete the tail, then traverse to the node just before the tail, delete the tail and set the penultimate node as the tail node.

In case of the middle node, u will have to use the concept of slow and fast pointers to locate the middle most node. suppose 5 is the middle node and 4->5->6 this is the setting. Here you delete the node containing five and and set 4’s next to 6.

Please try implementing it using the above concepts and if you face any difficulty, feel free to revert.

If my solution is able to clear your query,please mark the doubt as resolved.