tutorial 4 finished; not sure if works correctly at the last part of tutorial