moved comments into function bodies as per PEP8