review: storage scheme for cons cells
- word of memory is 4 bytes = 32 bits
- each number, symbol or pointer takes 1 word
- 4 bits used for type tag, 28 for data
P pair type
N number type
E empty list
F forwarding pointer
- cons cell uses 2 words, one for car and one for cdr
example: box and pointer diagram above might be stored like this:
- 100: N008
- 104: P132
- 108: N006
- 112: P100
- 116: N007
- 120: P108
- 124: N004
- 128 P116
- 132: P100 <— x (the root)
- 136: P108