Arm interview question

How to extract bits from an integer.