Lets look at very basic implementation of `Bitset`. 

```
struct Bitset {
    bool mask[32];

    bool& operator[] (int index) {
        return mask[index];
    }
};

```

Now I can write

```
Bitset bitset;
bitset[0] = 1;
std::cout << bitset[0] << "\n";

```

There is possible optimization. I can use `unsigned int` instead of `bool mask[32]`.

```
struct Bitset {
    unsigned int mask;

    bool& operator[] (int index) {
        // ??
    }
};

```

Is it possible to write `bool& operator[] (int index)` with such specification ? I think `std::bitset` is doing something like that but i have no idea how.