Arista Networks Interview Question

A bit manipulation question in C++