Answer: GENERAL ELECTRIC AVIATION | Off-Campus | Online Assessment(2023)

Answer · Posted Jun 2026

Approach Compare the least significant bit of a, b, and c. If the current bit of c is: 1: At least one of a or b must have a 1. 0: Both bits in a and b must be 0. Count the required flips. Right shift all numbers and repeat until all bits are processed. Strategy Process one bit at a time using bitwise operations. Use AND (&) to extract the current bit. Use right shift (>>) to move to ...

The full answer & interview discussion are available to premium members.

Log in Create a free account