Update README.md

Can't use assignment inside lambdas, use setattr() instead