I'd suggest adding test cases in which xlow<0 (and maybe also xhigh<0).
236 Solvers
Back to basics 9 - Indexed References
397 Solvers
Longest run of consecutive numbers
2011 Solvers
232 Solvers
Create an n-by-n null matrix and fill with ones certain positions
294 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!