Updated functions from group discussion in class