Home » C Programming » Bitwise Operators

What will be the output of the program? #include int main() { printf("%d %d\n", 32<<1, 32<<0); printf("%d %d\n", 32<<-1, 32<<-0); printf("%d %d\n", 32>>1, 32>>0); printf("%d %d\n", 32>>-1, 32>>-0); return 0; }

Correct Answer: 64 32 0 32 16 32 0 32

← Previous Question Next Question→

Discussion & Comments

No comments yet. Be the first to comment!
Join Discussion