310 Lab4 Code