#include <iostream> using namespace std; struct node{ int data; struct node* next; }; int main() { node* head = new node; head-> data = 10; head-> next = NULL; cout << "1st node is "<< head-> data << endl; node* current = new node; current-> data = 20; current-> next = NULL; head-> next = current; cout << "1st node is "<< current-> data << endl; current-> data = 30; current-> next = NULL; head-> next ->next = current; cout << "3rd node is "<< current-> data << endl; }