Advertisement
Guest User

Untitled

a guest
Jul 17th, 2019
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.29 KB | None | 0 0
  1. Node* p;
  2. p = new Node;
  3. p->firstname = firstName;
  4. p->lastname = lastName;
  5. p->value = value;
  6.  
  7. if (rosterEmpty() == true)
  8. {
  9. head = p;
  10. tail = p;
  11. head->next = nullptr;
  12. p->prev = nullptr;
  13. }
  14. else {
  15. tail->next = p;
  16. p->prev = tail;
  17. tail = p;
  18. tail->next = nullptr;
  19.  
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement