update README.md. add comments to code