lab8 code