Memory Allocator

Hard · Coding · 75 min

Implement a fixed-capacity contiguous memory allocator with lowest-address first-fit malloc, address-only free with neighbor coalescing, in-place or relocating realloc, and an O(log C) segment-tree FastAllocator.

This is a Pro problem. Pro unlocks the full prompt, a step-by-step walkthrough, a reference solution and tests you can run.

See Pro plans

More OpenAI problems