finished tutorial and commented code