About this question

The Poisoned Wine: Bitmasking

Hard · Brainteasers · Quant Trader interview question · bitwise-operations, binary, optimization

You are reviewing code that attempts to identify a poisoned bottle among 1000 bottles using 10 test strips. The function assign_strips returns a list of lists, where stripsi contains the bottle IDs to be tested on the $i$-th strip. Why does the developer use the bitwise AND operator (&) in line 4?