#ifndef COOKIEH #define COOKIEH class cookie { static const size_t n = 1000; //can allocate this many cookies static char buffer[]; static bool b[n]; //true if this slot is currently allocated public: void *operator new(size_t); void operator delete(void *p); }; #endif