Does lower_bound() return the same result with reverse iterators of a vector in increasing order vs forward iterators of a vector in decreasing order?
If I have 2 vectors, one in increasing order, and other decreasing:
Does lower_bound() return the same result with reverse iterators of a vector in increasing order vs forward iterators of a vector in decreasing order?
If I have 2 vectors, one in increasing order, and other decreasing:
Are these 2 exactly same –> “lower_bound(inc.rbegin(), inc.rend(), i , greater())” & “lower_bound(dec.begin(), dec.end(), i, greater())”
If i have say 2 vectors, one in increasing order, and other decreasing
vector<int> inc{1,2,3,4,6,7}, dec{7,6,4,3,2,1};
Are these 2 exactly same –> “lower_bound(inc.rbegin(), inc.rend(), i , greater())” & “lower_bound(dec.begin(), dec.end(), i, greater())”
If i have say 2 vectors, one in increasing order, and other decreasing
vector<int> inc{1,2,3,4,6,7}, dec{7,6,4,3,2,1};