updated example snippets in README.md