updated day 10 sample code