Amazon Interview Question

implement heap memory using 1024 bytes + memory beginning address