今天我在问自己,获取排序vector中所有值的最短代码可能是什么std::vector,大于或等于a小于或等于b.我的第一种方法类似于以下内容:#include#include#include#include//ReturnsallvaluesinsortedValuesbeinggreaterequalstartandsmallerequalend;std::vectorcutValues(conststd::vector&sortedValues,doublestart,doubleend){std::vectorret;autostartIter=std::lower_bound