Error in range example: fixes #272