app.js tweak
added .env file, which is needed to pull heroku's environmental variables and use them locally
cleaning up logic in averaging function