function to print the list
static void printList ( Node head ) { Node temp = head ; while ( temp . next != head ) { Console . Write ( temp . data + " ▁ " ) ; temp = temp . next ; } Console . Write ( temp . data + " ▁ " ) ; }