worked on sml homework 5 & 6