print singly linked list

PHOTO EMBED

Wed Jul 17 2024 12:00:47 GMT+0000 (Coordinated Universal Time)

Saved by @vishnu_jha #c++ #dsa #linkedlist #insertinlast #print

void print (node* &head) {
  node* temp = head;
  while (temp != NULL) {
    cout << temp -> data << " ";
    temp = temp -> next;
  }
}
content_copyCOPY

https://youtu.be/q8gdBn9RPeI?list=PLDzeHZWIZsTryvtXdMr6rPh4IDexB5NIA