Fall 2010 CSCI 255 Homework 1

This assignment is due in class or to my office assistant in RH 215 by 3:00 pm on 31 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. 2010

Problem 3

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

  1. 16
  2. -16
  3. 255
  4. -255
  5. 0
  6. -0

Problem 4

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

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

Problem 5

For numbers are stored in 6-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?