Driver code
public static void Main ( ) { Node head = newNode ( 1 ) ; head . next = newNode ( 2 ) ; head . next . next = newNode ( 3 ) ; head . next . next . next = newNode ( 4 ) ; head . next . next . next . next = newNode ( 5 ) ; Console . WriteLine ( " Given ▁ Linked ▁ List " ) ; printlist ( head ) ; head = rearrangeEvenOdd ( head ) ; Console . WriteLine ( " Modified ▁ Linked ▁ List " ) ; printlist ( head ) ; } }