Fall 2013 CSCI 255 Homework 2

This assignment is due in class or to my office assistant in RRO 215 by 10:00 AM on 28 August.

Problem 1

Convert the following unsigned binary numbers into decimal numbers.

  1. 11111
  2. 10101
  3. 11101000

Problem 2

Convert the following decimal numbers into binary numbers.

  1. 16
  2. 255
  3. 2012

Problem 3

Convert the following signed decimal numbers into 8-bit twos-complement representation.

  1. 32
  2. -32
  3. 100
  4. -100
  5. 0
  6. -0

Problem 4

Convert the following 5-bit twos-complement numbers into signed decimal numbers.

  1. 00000
  2. 01010
  3. 10000
  4. 10110
  5. 11000

Problem 5

For numbers stored in 16-bit words,

  1. what is the smallest unsigned number that can be stored?
  2. what is the largest unsigned number that can be stored?
  3. what is the smallest twos-complement number that can be stored?
  4. what is the largest twos-complement number that can be stored?