Say I have a set
s={1 5 10}
Now if I run a loop for [0,2] and everytime check for the strictly lower than upper bound of the set tha