Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void dic(node*& head, node*& tail)
- {
- int count = 1;
- node* temp = new node;
- temp = head;
- while (temp != NULL)
- {
- if (count == 4)
- {
- temp->data += 20;
- }
- else if(count == 6)
- {
- temp->data += 20;
- }
- temp = temp->next;
- count++;
- }
- temp = head;
- cout << "\n\nprint it\n\n";
- while (temp != NULL)
- {
- cout << "--| " << temp->data << endl;
- temp = temp->next;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment