Advertisement
Guest User

Untitled

a guest
Apr 26th, 2018
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.26 KB | None | 0 0
  1. Pool::Pool()
  2. {
  3.     for (int i = 0; i < maxPoolSize; ++i)
  4.     {
  5.         if (head == NULL) {
  6.             head = new memory;
  7.             current = head;
  8.         } else {
  9.             current->next = new memory;
  10.             current = current->next;
  11.             cout << "Pool object # "<< i << " created" << endl;
  12.         }
  13.     }
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement