Updated code lab 3.