#include <iostream>
#include <algorithm>
#include <vector>
int main() {
std::vector<int> unsorted = {10, 20, 5, 15, 25};
auto lb = std::lower_bound(unsorted.begin(), unsorted.end(), 15);
auto ub = std::upper_bound(unsorted.begin(), unsorted.end(), 15);
std::cout << "Lower Bound: " << (lb - unsorted.begin()) << std::endl;
std::cout << "Upper Bound: " << (ub - unsorted.begin()) << std::endl;
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgojaW5jbHVkZSA8YWxnb3JpdGhtPgojaW5jbHVkZSA8dmVjdG9yPgoKaW50IG1haW4oKSB7CiAgICBzdGQ6OnZlY3RvcjxpbnQ+IHVuc29ydGVkID0gezEwLCAyMCwgNSwgMTUsIDI1fTsKICAgIAogICAgYXV0byBsYiA9IHN0ZDo6bG93ZXJfYm91bmQodW5zb3J0ZWQuYmVnaW4oKSwgdW5zb3J0ZWQuZW5kKCksIDE1KTsKICAgIGF1dG8gdWIgPSBzdGQ6OnVwcGVyX2JvdW5kKHVuc29ydGVkLmJlZ2luKCksIHVuc29ydGVkLmVuZCgpLCAxNSk7CiAgICAKICAgIHN0ZDo6Y291dCA8PCAiTG93ZXIgQm91bmQ6ICIgPDwgKGxiIC0gdW5zb3J0ZWQuYmVnaW4oKSkgPDwgc3RkOjplbmRsOwogICAgc3RkOjpjb3V0IDw8ICJVcHBlciBCb3VuZDogIiA8PCAodWIgLSB1bnNvcnRlZC5iZWdpbigpKSA8PCBzdGQ6OmVuZGw7CgogICAgcmV0dXJuIDA7Cn0K