Updated Scheme code