Finding Which Packed Indexes are 1

In reply to srishis:

Well the Original Question does say using Array Locator methods
( which returns a Queue by default )

Also your original comment ::

“It is always recommended to use the queue push_back() or push_front() method instead of assigning value directly to the queue

Is Incorrect in my case . The LRM clearly states these methods return a Queue .
It even has examples with the same