readme and code updated