Skip to content
Related Articles

Related Articles

Improve Article
Save Article
Like Article

ISRO | ISRO CS 2007 | Question 18

  • Last Updated : 20 Nov, 2018

The number of digit 1 present in the binary representation of

3 × 512 + 7 × 64 + 5 × 8 + 3

(A) 8
(B) 9
(C) 10
(D) 12


Answer: (B)

Explanation:

3 × 512 + 7 × 64 + 5 × 8 + 3
= (2 + 1)× 512 + (4 + 2 + 1)× 64 + (4 + 1)× 8 + 2 + 1

= 1024 + 512 + 64 x 4 + 64 x 2 + 64 + 32 + 8 + 2 + 1
= 1024 + 512 + 256 + 128 + 64 + 32 + 8 + 2 + 1
As 1024 has ten 0’s followed by 1, 512 has nine 0’s followed by 1 and so on..
So, the expression will contain total nine 1’s and will be be represented as 11111101011.

Option (B) is correct.

Quiz of this Question

My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!