Question PSC-BIT-0005
EasyWhat will be the output of the following pseudocode?
Integer x = 3
Print x << 3
- A.
11
- B.
6
- C.
Show answer and explanation
Answer: C
Shifting left by 3 multiplies by 2³ = 8: 3 × 8 = 24.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Bitwise Operators question
What will be the output of the following pseudocode?
Integer x = 3
Print x << 3
11
6
Answer: C
Shifting left by 3 multiplies by 2³ = 8: 3 × 8 = 24.
24
9