working on sicp 3.1