Assignment 1, Solutions

Part of the homework for 22C:60, Fall 2009
by Douglas W. Jones
THE UNIVERSITY OF IOWA Department of Computer Science

  1. What is your E-mail address? (If you have more than one, give the address you'd prefer used for class purposes.)

    No solution offered

    Real Homework!

  2. Background: The most interesting character set supported by any printing device in the 1950's was that of the Fridden Flex-O-Writer. One version of this had 86 printable characters and 8 control codes.

    Question: The Flex-O-Writer did not have an obvious "best" size for characters. Briefly discuss how you would go about supporting this character set on a computer with a 6-bit character code. (1 point)

    86 characters is greater than 26, so if character codes are constrained to be 6 bits, we will need to reserve 2 codes, one for shift in, and one for shift out. For example, we might divide the 86 characters into 43 lower and 43 upper case characters, with shift in and shift out used to switch between lower and upper case.

    If the 86 characters include alll 26 upper case and 26 lower case characters of the Roman alphabet, that implies that there are 24 other printable characters, probably 10 numerals plus 14 punctuation marks. If we make the shift codes apply only to characters in the Roman alphabet, while all punctuation and digits appear identically in upper and lower case, that means that we have 50 printable characters in each case. Given that a 6-bit code allows 64 characters, total, this means we have room for 14 control characters, including space, shift-in and shift-out.

  3. Show what "22C:60, 10:30 MWF, 221 MLH" would look like as a punched paper tape in the ILLIAC I character encoding. Don't include the quotes. (1 point)
    F/S |OOo OO|
    2   |  o O |
    2   |  o O |
    L/S |O oO  |
    C   |OOoO O|
    F/S |OOo OO|
    :   |OOoO O|
    6   |  oOO |
    0   |  o   |
    ,   |O oO O|
        |OOoOOO|
    1   |  o  O|
    0   |  o   |
    :   |OOoO O|
    3   |  o OO|
    0   |  o   |
        |OOoOOO|
    L/S |O oO  |
    M   |OOo O |
    W   |  o O |
    F   | OoOO |
    F/S |OOo OO|
    ,   |O oO O|
        |OOoOOO|
    2   |  o O |
    2   |  o O |
    1   |  o  O|
        |OOoOOO|
    L/S |O oO  |
    M   |OOo O |
    L   | OoOOO|
    H   |OOoO  |
    

  4. Give the 7-bit ASCII representation of the text "22C:60, 10:30 MWF, 221 MLH" Don't include the quotes. Give your result as a column of binary numbers. (1 point)
    2   011 0010
    2   011 0010
    C   100 0011
    :   011 1010
    6   011 0110
    0   011 0000
    ,   010 1100
        010 0000
    1   011 0001
    0   011 0000
    :   011 1010
    3   011 0011
    0   011 0000
        010 0000
    M   100 1101
    W   101 0111
    F   100 0110
    ,   010 1100
        010 0000
    2   011 0010
    2   011 0010
    1   011 0001
        010 0000
    M   100 1101
    L   100 1100
    H   100 1000