Swapping two nodes
 Given a linked list and two characters to swap ,  WE NEED TO SWAP TWO NODES NOT THE VALUES given.   Algorithm  step 1- start traversing the linked list  step 2- assign the nodes which contain the given values as t1 and t2.respectively  step 3- assign the previous nodes before the nodes contain the given values as p1 and p2  step 4-assign p1 next node to t2  step 5-assign p2 next node to t1  step 6-assign t1 next node to t2 next node  step 7-at last assign assign t2 next node to p2  step 8-end   For example  the given linked list be  1->2->3->4->5->null   swap 3 and 5   according to the algorithm  p1 node will be 2  t1 node will be 3  p2 node will be 4  t2 node will be 5   then while we execute the below code          p1.next=t2;          p2.next=t1;          t1.next=t2.next;          t2.next=p2;  the nodes get swapped.   output will be 1->2->5->4->3->null   Code  public class L...