modify search_for_a_range.cpp