Function to print the data present in all the nodes
static void print ( node head ) { node curr = head ; while ( curr != null ) { Console . Write ( curr . data + " ▁ - > ▁ " ) ; curr = curr . next ; } }