Question DSA-BIT-0039
EasyFor a non-negative integer, what does a right shift by 1 (n >> 1) do?
- A.
Divides it by 2, dropping any remainder
- B.
Makes it negative
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Bit Manipulation question
For a non-negative integer, what does a right shift by 1 (n >> 1) do?
Divides it by 2, dropping any remainder
Makes it negative
Sign up free to see the answer and a step-by-step explanation.
Adds 1
Multiplies it by 2