Another Approach for lotto question done in video at 41:37

please tell me the bitmasking appraoch for lotto question , sir has told in first video of STL.