GATE Computer ScienceVery hardGATE CS (PYQ pattern)

How many of the 2³² IEEE 754 single-precision bit patterns represent a finite value that is an integer (both zeros included, both signs counted)?

  1. A. 1761607680 (= 105 × 2²⁴)
  2. B. 1778384896 (= 212 × 2²³)
  3. C. 889192448 (= 106 × 2²³)
  4. D. 1778384898 (= 212 × 2²³ + 2)

Correct answer: B. 1778384896 (= 212 × 2²³)

Per sign: the zero (1 pattern); denormals and exponents below 0 are never integers except zero; unbiased exponent e = 0..22 needs the low 23 − e fraction bits zero, giving 2^e patterns, Σ = 2²³ − 1; e = 23..127 (105 exponents) are all integers, 105 × 2²³. Sum 1 + (2²³ − 1) + 105 × 2²³ = 106 × 2²³; doubled for both signs: 212 × 2²³ = 1778384896.

More Digital Logic questions

Exams that ask this topic