rewrite range operator