IPA IP 2020 Question 62

A question IPA Japan published in 令和2年度 10月 ITパスポート試験 公開問題 問62, translated into English. ITPEC is based on the same exams.

Same question on ITPEC: Apr 2026 Q4 +1 more

Which of the following represents the decimal number 155 in binary?

Explanation

10011011 — 155 is 128 + 16 + 8 + 2 + 1.

Subtract the largest power of two that fits, from 128 down:

  • •155 − 128 = 27: the 128 bit is 1
  • •64 and 32 do not fit into 27: those bits are 0
  • •27 − 16 = 11: the 16 bit is 1
  • •11 − 8 = 3: the 8 bit is 1
  • •4 does not fit into 3: that bit is 0
  • •3 − 2 = 1, then 1 − 1 = 0: the 2 and 1 bits are 1

Reading the bits from 128 to 1 gives 10011011.

Answer (a)

Why not others:

  • •(b) 10110011 — 128 + 32 + 16 + 2 + 1 = 179
  • •(c) 11001101 — 128 + 64 + 8 + 4 + 1 = 205
  • •(d) 11011001 — 217; it is the answer written backwards, the slip made when the remainders of repeated division by 2 are read from first to last instead of last to first

Key rule: To convert decimal to binary, divide by 2 repeatedly and read the remainders from the last one up, or subtract powers of two from the largest; check by adding the weights of the 1 bits.

Basic Theory · AI-written, may contain errors

This question comes from the past questions IPA Japan publishes, translated into English by ITPEC Practice. ITPEC Practice is an independent study tool and is not affiliated with IPA or ITPEC. See the original paper (PDF) or Report an issue.