finished implementation of lab 6, objective 1