Optimization: delay computing len of numeric_range until needed · Issue #673 · more-itertools/more-itertools · GitHub
More Web Proxy on the site http://driver.im/
You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Instead of always computing _len in __init__, we can delay the computation until it is used. For simple iteration over the range, we can avoid computing it entirely. For other uses it will add negligible overhead.