corrects flake8 errors

also a couple little changes in the examples