Topic: Bit Manipulation Problem / Level: beginner

Problem: Write a function to find the maximum number of 1s that can be obtained by flipping exactly one bit in a binary number.

Run the code to see the output here...