What is the result of 16>>2 ? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
- 4

What is the result of 16>>2 ?

B.sc. 1year c language question.

23rd Feb 2020, 3:38 AM
Priyansh Yadav
Priyansh Yadav - avatar
4 Answers
+ 2
Priyansh Yadav it is bitwise right shift operator. It takes two numbers, right shifts the bits of the first operand, the second operand decides the number of places to shift.Similarly right shifting (x>>y) is equivalent to dividing x with 2^y. Sample code👇 https://code.sololearn.com/chdL3p63H0n7/?ref=app
23rd Feb 2020, 5:10 AM
Arsenic
Arsenic - avatar
+ 1
Sir , is it an operator? How does it manipulate operands?
23rd Feb 2020, 3:58 AM
Priyansh Yadav
Priyansh Yadav - avatar
+ 1
Intro to bitwise operator 👍 https://www.sololearn.com/learn/4070/?ref=app
23rd Feb 2020, 4:03 AM
Ipang