fixed compile errors in README.md example code