Homework for LAB7 solved IMHO