Example code updated