small refactor of sample code in README.