iteration: checks ranges on iteration even if index isn't sorted. Use bsearch for checking if the key from ranges.
stress: added tests for iteration: out of ranges, part of ranges and full range.