Design a Bitmap Block Allocator (continuous allocation, holes counting)

Problem: Implement a Bitmap Block Allocator (continuous allocation, holes counting)

Implement a bitmap-based allocator BitmapBlock over M blocks: 0 means free, 1 means occupied.

You must ...

Example

Unlock to view complete problem details

and practice with sample input/output

Was this article helpful?

View Test Cases & Run Code requires membership

Standard Input
Execution Result: